gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-anastasis] branch master updated: fix tests


From: gnunet
Subject: [taler-anastasis] branch master updated: fix tests
Date: Mon, 08 Feb 2021 20:21:14 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository anastasis.

The following commit(s) were added to refs/heads/master by this push:
     new 6225f04  fix tests
6225f04 is described below

commit 6225f042f0ee656344326fe7c4fd0b908e3f9455
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Mon Feb 8 20:21:12 2021 +0100

    fix tests
---
 src/lib/anastasis_backup.c          |  2 +-
 src/testing/test_anastasis.c        | 13 +++++++++++--
 src/testing/test_anastasis_api.c    |  4 ++++
 src/testing/test_anastasis_api.conf | 30 ++++++++++++------------------
 4 files changed, 28 insertions(+), 21 deletions(-)

diff --git a/src/lib/anastasis_backup.c b/src/lib/anastasis_backup.c
index 726ce8f..4776b3b 100644
--- a/src/lib/anastasis_backup.c
+++ b/src/lib/anastasis_backup.c
@@ -632,7 +632,7 @@ get_num_urls (const struct ANASTASIS_Policy *policies[],
     {
       bool found = false;
 
-      for (unsigned int l = 0; l < i; l++)
+      for (unsigned int l = 0; l <= i; l++)
       {
         for (unsigned int k = 0; k < policies[l]->truths_length; k++)
         {
diff --git a/src/testing/test_anastasis.c b/src/testing/test_anastasis.c
index 642131a..f868977 100644
--- a/src/testing/test_anastasis.c
+++ b/src/testing/test_anastasis.c
@@ -407,13 +407,22 @@ main (int argc,
     if (NULL == (merchantd =
                    TALER_TESTING_run_merchant (CONFIG_FILE,
                                                merchant_url)))
+    {
+      GNUNET_break (0);
       return 1;
-
+    }
     if (NULL == (anastasisd =
                    ANASTASIS_TESTING_run_anastasis (CONFIG_FILE,
                                                     anastasis_url)))
-      return 1;
+    {
+      GNUNET_break (0);
+      GNUNET_OS_process_kill (merchantd,
+                              SIGTERM);
+      GNUNET_OS_process_wait (merchantd);
+      GNUNET_OS_process_destroy (merchantd);
 
+      return 1;
+    }
     ret = TALER_TESTING_setup_with_exchange (&run,
                                              NULL,
                                              CONFIG_FILE);
diff --git a/src/testing/test_anastasis_api.c b/src/testing/test_anastasis_api.c
index 6cca607..32dccfa 100644
--- a/src/testing/test_anastasis_api.c
+++ b/src/testing/test_anastasis_api.c
@@ -371,6 +371,10 @@ main (int argc,
                                                     anastasis_url)))
     {
       GNUNET_break (0);
+      GNUNET_OS_process_kill (merchantd,
+                              SIGTERM);
+      GNUNET_OS_process_wait (merchantd);
+      GNUNET_OS_process_destroy (merchantd);
       return 1;
     }
     hash = ANASTASIS_TESTING_make_hashed_answer ("Hashed-Answer",
diff --git a/src/testing/test_anastasis_api.conf 
b/src/testing/test_anastasis_api.conf
index 0c01271..6d56511 100644
--- a/src/testing/test_anastasis_api.conf
+++ b/src/testing/test_anastasis_api.conf
@@ -44,6 +44,9 @@ PORT = 8086
 
 DB = postgres
 
+# Upload limit
+UPLOAD_LIMIT_MB = 1
+
 INSURANCE = EUR:0
 
 SERVER_SALT = salty
@@ -60,36 +63,27 @@ ANNUAL_FEE = EUR:4.99
 #ANNUAL_FEE = EUR:0
 
 # Authentication costs
-
+[authorization-question]
 # Cost of authentication by question
-QUESTION_COST = EUR:0
+COST = EUR:0
 
+[authorization-file]
 # Cost of authentication by file (only for testing purposes)
-FILE_COST = EUR:1
+COST = EUR:1
 
+[authorization-email]
 # Cost of authentication by E-Mail
-#EMAIL_COST = EUR:0
+COST = EUR:0
 
+[authorization-sms]
 # Cost of authentication by SMS
-#SMS_COST = EUR:0
-
-# Cost of authentication by postal
-#POSTAL_COST = EUR:0
-
-# Cost of authentication by video
-#VIDEO_COST = EUR:0
-
-# Command which is executed for the sms authentication
-SMSAUTH_COMMAND = ./sms_authentication.sh
+COST = EUR:0
 
 # Command which is executed for the sms authentication
-# EMAILAUTH_COMMAND =
+COMMAND = ./sms_authentication.sh
 
 
-# Upload limit
-UPLOAD_LIMIT_MB = 1
 
-SUPPORTED_METHODS = question
 
 # This specifies which database the postgres backend uses.
 [stasis-postgres]

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]