summaryrefslogtreecommitdiff
path: root/src/testing
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-05-25 20:10:46 +0200
committerChristian Grothoff <christian@grothoff.org>2021-05-25 20:10:46 +0200
commitb2b1f88ab617ee9a01ac263b8b1c679f24277076 (patch)
tree7a09ee976f7b0e33cf23139be5a7377c8085b7f5 /src/testing
parentdd323a5d9cff357a4e12777250b9cf77c5de0721 (diff)
downloadexchange-b2b1f88ab617ee9a01ac263b8b1c679f24277076.tar.gz
exchange-b2b1f88ab617ee9a01ac263b8b1c679f24277076.tar.bz2
exchange-b2b1f88ab617ee9a01ac263b8b1c679f24277076.zip
add HTTP status argument to testin gCMD admin_add_incoming_with_ref for merchant tests
Diffstat (limited to 'src/testing')
-rw-r--r--src/testing/test_bank_api.c3
-rw-r--r--src/testing/testing_api_cmd_bank_admin_add_incoming.c9
2 files changed, 7 insertions, 5 deletions
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);
}