merchant

Merchant backend to process payments, run by merchants
Log | Files | Refs | Submodules | README | LICENSE

commit f641e252f0ae2e6ebc0cb5520363f69b65427c8b
parent c8b6ad8abd3a9bd2491262fc9cb881b9b491969d
Author: Jonathan Buchanan <jonathan.russ.buchanan@gmail.com>
Date:   Mon, 29 Jun 2020 15:51:40 -0400

got tips test working again

Diffstat:
Msrc/backend/taler-merchant-httpd_reserves.c | 2+-
Msrc/testing/test_merchant_api.c | 11++++++++---
2 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/src/backend/taler-merchant-httpd_reserves.c b/src/backend/taler-merchant-httpd_reserves.c @@ -179,7 +179,7 @@ reserve_cb (void *cls, try_later (r); return; } - if (0 != + if (GNUNET_OK != TALER_amount_cmp_currency (&r->expected_amount, balance)) { diff --git a/src/testing/test_merchant_api.c b/src/testing/test_merchant_api.c @@ -721,6 +721,10 @@ run (void *cls, payer_payto, "create-reserve-tip-1"), cmd_exec_wirewatch ("wirewatch-3"), + /* Sleep so the merchant discovers that the reserve exists at the exchange + before trying to authorize a tip. */ + TALER_TESTING_cmd_sleep ("wait-reserve-1", + 1), TALER_TESTING_cmd_tip_authorize ("authorize-tip-1", merchant_url, EXCHANGE_URL, @@ -748,6 +752,7 @@ run (void *cls, TALER_TESTING_cmd_merchant_get_reserves ("get-reserves-1", merchant_url, MHD_HTTP_OK, + "create-reserve-tip-1", NULL), TALER_TESTING_cmd_merchant_get_reserve ("get-reserve-1", merchant_url, @@ -820,6 +825,8 @@ run (void *cls, payer_payto, "create-reserve-tip-2"), cmd_exec_wirewatch ("wirewatch-4"), + TALER_TESTING_cmd_sleep ("wait-reserve-2", + 1), TALER_TESTING_cmd_tip_authorize_from_reserve_with_ec ( "authorize-tip-insufficient-funds", merchant_url, @@ -1175,11 +1182,9 @@ run (void *cls, #endif TALER_TESTING_cmd_batch ("refund", refund), -#if 0 -// #endif TALER_TESTING_cmd_batch ("tip", tip), -// #if 0 +#if 0 TALER_TESTING_cmd_batch ("pay-again", pay_again), TALER_TESTING_cmd_batch ("pay-abort",