gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] branch master updated: add HTTP status argument to test


From: gnunet
Subject: [taler-exchange] branch master updated: add HTTP status argument to testin gCMD admin_add_incoming_with_ref for merchant tests
Date: Tue, 25 May 2021 20:10:48 +0200

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 b2b1f88a add HTTP status argument to testin gCMD 
admin_add_incoming_with_ref for merchant tests
b2b1f88a is described below

commit b2b1f88ab617ee9a01ac263b8b1c679f24277076
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Tue May 25 20:10:46 2021 +0200

    add HTTP status argument to testin gCMD admin_add_incoming_with_ref for 
merchant tests
---
 src/include/taler_testing_lib.h                       | 4 +++-
 src/testing/test_bank_api.c                           | 3 ++-
 src/testing/testing_api_cmd_bank_admin_add_incoming.c | 9 +++++----
 3 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/src/include/taler_testing_lib.h b/src/include/taler_testing_lib.h
index c0a76c44..f15a5f76 100644
--- a/src/include/taler_testing_lib.h
+++ b/src/include/taler_testing_lib.h
@@ -1147,6 +1147,7 @@ TALER_TESTING_cmd_admin_add_incoming (
  * @param auth authentication data
  * @param ref reference to a command that can offer a reserve
  *        private key or public key.
+ * @param http_status expected HTTP status
  * @return the command.
  */
 struct TALER_TESTING_Command
@@ -1155,7 +1156,8 @@ TALER_TESTING_cmd_admin_add_incoming_with_ref (
   const char *amount,
   const struct TALER_BANK_AuthenticationData *auth,
   const char *payto_debit_account,
-  const char *ref);
+  const char *ref,
+  unsigned int http_status);
 
 
 /**
diff --git a/src/testing/test_bank_api.c b/src/testing/test_bank_api.c
index 98f97cd4..68c12aff 100644
--- a/src/testing/test_bank_api.c
+++ b/src/testing/test_bank_api.c
@@ -91,7 +91,8 @@ run (void *cls,
                                                      "KUDOS:2.01",
                                                      &bc.exchange_auth,
                                                      bc.user42_payto,
-                                                     "credit-1"),
+                                                     "credit-1",
+                                                     MHD_HTTP_CONFLICT),
       TALER_TESTING_cmd_sleep ("Waiting 4s for 'credit-1' to settle",
                                4),
       TALER_TESTING_cmd_bank_credits ("history-1c",
diff --git a/src/testing/testing_api_cmd_bank_admin_add_incoming.c 
b/src/testing/testing_api_cmd_bank_admin_add_incoming.c
index aaa447fe..28f907fd 100644
--- a/src/testing/testing_api_cmd_bank_admin_add_incoming.c
+++ b/src/testing/testing_api_cmd_bank_admin_add_incoming.c
@@ -557,12 +557,13 @@ TALER_TESTING_cmd_admin_add_incoming (const char *label,
 
 
 struct TALER_TESTING_Command
-TALER_TESTING_cmd_admin_add_incoming_with_ref
-  (const char *label,
+TALER_TESTING_cmd_admin_add_incoming_with_ref (
+  const char *label,
   const char *amount,
   const struct TALER_BANK_AuthenticationData *auth,
   const char *payto_debit_account,
-  const char *ref)
+  const char *ref,
+  unsigned int http_status)
 {
   struct AdminAddIncomingState *fts;
 
@@ -570,7 +571,7 @@ TALER_TESTING_cmd_admin_add_incoming_with_ref
                   auth,
                   payto_debit_account);
   fts->reserve_reference = ref;
-  fts->expected_http_status = MHD_HTTP_CONFLICT;
+  fts->expected_http_status = http_status;
   return make_command (label,
                        fts);
 }

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