gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] branch master updated: add setup steps to tests


From: gnunet
Subject: [taler-exchange] branch master updated: add setup steps to tests
Date: Fri, 11 Dec 2020 23:44:04 +0100

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

grothoff pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 2a3de655 add setup steps to tests
2a3de655 is described below

commit 2a3de6555abde9a7159187e01ee140192b155f25
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Fri Dec 11 23:44:01 2020 +0100

    add setup steps to tests
---
 src/auditor/.gitignore                               |  1 +
 src/testing/.gitignore                               | 14 ++++++++++++++
 src/testing/test_auditor_api.c                       | 12 ++++++++++++
 src/testing/test_exchange_api.c                      | 13 +++++++++++++
 src/testing/test_exchange_api_keys_cherry_picking.c  | 12 ++++++++++++
 src/testing/test_exchange_api_overlapping_keys_bug.c | 12 ++++++++++++
 src/testing/test_exchange_api_revocation.c           | 12 ++++++++++++
 src/testing/test_exchange_management_api.c           |  2 +-
 src/testing/test_taler_exchange_aggregator.c         | 16 ++++++++--------
 src/testing/test_taler_exchange_wirewatch.c          | 12 ++++++++++++
 10 files changed, 97 insertions(+), 9 deletions(-)

diff --git a/src/auditor/.gitignore b/src/auditor/.gitignore
index 7ad6c976..6ada1587 100644
--- a/src/auditor/.gitignore
+++ b/src/auditor/.gitignore
@@ -16,3 +16,4 @@ taler-helper-auditor-reserves
 taler-helper-auditor-wire
 generate-auditor-basedb-prod.conf
 generate-auditor-basedb-revocation.conf
+revocation-tmp-*
diff --git a/src/testing/.gitignore b/src/testing/.gitignore
index df5ddbfe..116c8f50 100644
--- a/src/testing/.gitignore
+++ b/src/testing/.gitignore
@@ -8,3 +8,17 @@ test_taler_exchange_wirewatch-postgres
 test_exchange_api_revocation
 report*
 test_exchange_management_api
+test_exchange_api_home/.local/share/taler/crypto-eddsa/
+test_exchange_api_home/.local/share/taler/crypto-rsa/
+test_exchange_api_home/.local/share/taler/exchange/offline-keys/secm_tofus.priv
+test_exchange_api_home/.local/share/taler/taler-helper-crypto-eddsa/
+test_exchange_api_home/.local/share/taler/taler-helper-crypto-rsa/
+test_exchange_api_keys_cherry_picking_home/.local/share/taler/crypto-eddsa/
+test_exchange_api_keys_cherry_picking_home/.local/share/taler/exchange/offline-keys/secm_tofus.priv
+test_exchange_api_keys_cherry_picking_home/.local/share/taler/taler-helper-crypto-eddsa/
+test_exchange_api_keys_cherry_picking_home/.local/share/taler/taler-helper-crypto-rsa/
+test_taler_exchange_httpd_home/.local/share/taler/crypto-eddsa/
+test_taler_exchange_httpd_home/.local/share/taler/crypto-rsa/
+test_taler_exchange_httpd_home/.local/share/taler/exchange/offline-keys/secm_tofus.priv
+test_taler_exchange_httpd_home/.local/share/taler/taler-helper-crypto-eddsa/
+test_taler_exchange_httpd_home/.local/share/taler/taler-helper-crypto-rsa/
diff --git a/src/testing/test_auditor_api.c b/src/testing/test_auditor_api.c
index 0ff28b29..f0184143 100644
--- a/src/testing/test_auditor_api.c
+++ b/src/testing/test_auditor_api.c
@@ -620,6 +620,18 @@ run (void *cls,
   };
 
   struct TALER_TESTING_Command commands[] = {
+    TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                   MHD_HTTP_NO_CONTENT,
+                                   false),
+    TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                "payto://x-taler-bank/localhost/2",
+                                MHD_HTTP_NO_CONTENT,
+                                false),
+    TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                              CONFIG_FILE),
+    TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                1,
+                                                5 /* FIXME: wrong number... 
*/),
     CMD_RUN_AUDITOR ("virgin-auditor"),
     TALER_TESTING_cmd_exchanges_with_url ("check-exchange",
                                           MHD_HTTP_OK,
diff --git a/src/testing/test_exchange_api.c b/src/testing/test_exchange_api.c
index d30597b2..d2e18c41 100644
--- a/src/testing/test_exchange_api.c
+++ b/src/testing/test_exchange_api.c
@@ -946,6 +946,19 @@ run (void *cls,
 
   {
     struct TALER_TESTING_Command commands[] = {
+      /* setup exchange */
+      TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                     MHD_HTTP_NO_CONTENT,
+                                     false),
+      TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                  "payto://x-taler-bank/localhost/2",
+                                  MHD_HTTP_NO_CONTENT,
+                                  false),
+      TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                                CONFIG_FILE),
+      TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                  1,
+                                                  5 /* FIXME: wrong number... 
*/),
       TALER_TESTING_cmd_batch ("wire",
                                wire),
       TALER_TESTING_cmd_batch ("withdraw",
diff --git a/src/testing/test_exchange_api_keys_cherry_picking.c 
b/src/testing/test_exchange_api_keys_cherry_picking.c
index ed11bd5e..aab94d68 100644
--- a/src/testing/test_exchange_api_keys_cherry_picking.c
+++ b/src/testing/test_exchange_api_keys_cherry_picking.c
@@ -206,6 +206,18 @@ run (void *cls,
     TALER_TESTING_cmd_end ()
   };
   struct TALER_TESTING_Command commands[] = {
+    TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                   MHD_HTTP_NO_CONTENT,
+                                   false),
+    TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                "payto://x-taler-bank/localhost/2",
+                                MHD_HTTP_NO_CONTENT,
+                                false),
+    TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                              CONFIG_FILE),
+    TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                1,
+                                                1 /* FIXME: wrong number... 
*/),
     TALER_TESTING_cmd_batch ("ordinary-cherry-pick",
                              ordinary_cherry_pick),
     TALER_TESTING_cmd_batch ("keys-serialization",
diff --git a/src/testing/test_exchange_api_overlapping_keys_bug.c 
b/src/testing/test_exchange_api_overlapping_keys_bug.c
index cfe33d51..19093243 100644
--- a/src/testing/test_exchange_api_overlapping_keys_bug.c
+++ b/src/testing/test_exchange_api_overlapping_keys_bug.c
@@ -71,6 +71,18 @@ run (void *cls,
      struct TALER_TESTING_Interpreter *is)
 {
   struct TALER_TESTING_Command commands[] = {
+    TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                   MHD_HTTP_NO_CONTENT,
+                                   false),
+    TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                "payto://x-taler-bank/localhost/2",
+                                MHD_HTTP_NO_CONTENT,
+                                false),
+    TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                              CONFIG_FILE),
+    TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                1,
+                                                1 /* FIXME: wrong number... 
*/),
     TALER_TESTING_cmd_check_keys ("first-download",
                                   1,
                                   1),
diff --git a/src/testing/test_exchange_api_revocation.c 
b/src/testing/test_exchange_api_revocation.c
index 0f3a8910..a952d360 100644
--- a/src/testing/test_exchange_api_revocation.c
+++ b/src/testing/test_exchange_api_revocation.c
@@ -62,6 +62,18 @@ run (void *cls,
      struct TALER_TESTING_Interpreter *is)
 {
   struct TALER_TESTING_Command revocation[] = {
+    TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                   MHD_HTTP_NO_CONTENT,
+                                   false),
+    TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                "payto://x-taler-bank/localhost/2",
+                                MHD_HTTP_NO_CONTENT,
+                                false),
+    TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                              CONFIG_FILE),
+    TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                1,
+                                                5 /* FIXME: wrong number... 
*/),
     /**
      * Fill reserve with EUR:10.02, as withdraw fee is 1 ct per
      * config.
diff --git a/src/testing/test_exchange_management_api.c 
b/src/testing/test_exchange_management_api.c
index 92b6e25a..26c6cae8 100644
--- a/src/testing/test_exchange_management_api.c
+++ b/src/testing/test_exchange_management_api.c
@@ -144,7 +144,7 @@ run (void *cls,
                                               CONFIG_FILE),
     TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
                                                 1,
-                                                5),
+                                                5 /* FIXME: wrong number... 
*/),
     TALER_TESTING_cmd_end ()
   };
 
diff --git a/src/testing/test_taler_exchange_aggregator.c 
b/src/testing/test_taler_exchange_aggregator.c
index d5c392d3..57e73cd1 100644
--- a/src/testing/test_taler_exchange_aggregator.c
+++ b/src/testing/test_taler_exchange_aggregator.c
@@ -96,7 +96,6 @@ run (void *cls,
      struct TALER_TESTING_Interpreter *is)
 {
   struct TALER_TESTING_Command all[] = {
-
     // check no aggregation happens on a empty database
     CMD_EXEC_AGGREGATOR ("run-aggregator-on-empty-db",
                          config_filename),
@@ -550,22 +549,23 @@ main (int argc,
 
   TALER_TESTING_cleanup_files (config_filename);
 
-  if (GNUNET_OK != TALER_TESTING_prepare_exchange (config_filename,
-                                                   GNUNET_YES,
-                                                   &ec))
+  if (GNUNET_OK !=
+      TALER_TESTING_prepare_exchange (config_filename,
+                                      GNUNET_YES,
+                                      &ec))
   {
     TALER_LOG_WARNING ("Could not prepare the exchange.\n");
     return 77;
   }
 
-  if (GNUNET_OK != TALER_TESTING_prepare_fakebank (config_filename,
-                                                   "exchange-account-1",
-                                                   &bc))
+  if (GNUNET_OK !=
+      TALER_TESTING_prepare_fakebank (config_filename,
+                                      "exchange-account-1",
+                                      &bc))
   {
     TALER_LOG_WARNING ("Could not prepare the fakebank\n");
     return 77;
   }
-
   if (GNUNET_OK !=
       GNUNET_CONFIGURATION_parse_and_run (config_filename,
                                           &prepare_database,
diff --git a/src/testing/test_taler_exchange_wirewatch.c 
b/src/testing/test_taler_exchange_wirewatch.c
index fbcf742f..b16a9e76 100644
--- a/src/testing/test_taler_exchange_wirewatch.c
+++ b/src/testing/test_taler_exchange_wirewatch.c
@@ -82,6 +82,18 @@ run (void *cls,
      struct TALER_TESTING_Interpreter *is)
 {
   struct TALER_TESTING_Command all[] = {
+    TALER_TESTING_cmd_auditor_add ("add-auditor-OK",
+                                   MHD_HTTP_NO_CONTENT,
+                                   false),
+    TALER_TESTING_cmd_wire_add ("add-wire-account",
+                                "payto://x-taler-bank/localhost/2",
+                                MHD_HTTP_NO_CONTENT,
+                                false),
+    TALER_TESTING_cmd_exec_offline_sign_keys ("offline-sign-future-keys",
+                                              config_filename),
+    TALER_TESTING_cmd_check_keys_pull_all_keys ("refetch /keys",
+                                                1,
+                                                5 /* FIXME: wrong number... 
*/),
     TALER_TESTING_cmd_check_bank_empty ("expect-empty-transactions-on-start"),
     CMD_EXEC_AGGREGATOR ("run-aggregator-on-empty"),
     TALER_TESTING_cmd_exec_wirewatch ("run-wirewatch-on-empty",

-- 
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]