commit a54daf35f13591a17a07da9f63479ac7fea27225
parent 938c7f06d6f28a1369ffd7a2416aab5267dd398e
Author: Marcello Stanisci <stanisci.m@gmail.com>
Date: Mon, 26 Mar 2018 10:33:51 +0200
fix tipping test aftermath.
Diffstat:
2 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/src/lib/test_merchant_api_new.c b/src/lib/test_merchant_api_new.c
@@ -629,6 +629,14 @@ run (void *cls,
"EUR:4.99", // amount - fee
"EUR:0.01"), // refund fee
+ CMD_EXEC_AGGREGATOR ("aggregator-tip-1"),
+ TALER_TESTING_cmd_check_bank_transfer
+ ("check_bank_transfer-tip-498c",
+ "http://localhost:8081/",
+ "EUR:4.98", EXCHANGE_ACCOUNT_NO, USER_ACCOUNT_NO),
+ TALER_TESTING_cmd_check_bank_empty
+ ("check_bank_empty-at-tips"),
+
/* pay again logic. */
TALER_TESTING_cmd_fakebank_transfer
("create-reserve-10",
@@ -647,9 +655,6 @@ run (void *cls,
"http://localhost:8081/",
"EUR:10.02", USER_ACCOUNT_NO, EXCHANGE_ACCOUNT_NO),
- /* This is not found at the original tests. */
- TALER_TESTING_cmd_check_bank_empty ("be_sure"),
-
TALER_TESTING_cmd_withdraw_amount ("withdraw-coin-10a",
is->exchange,
"create-reserve-10",
@@ -719,8 +724,6 @@ run (void *cls,
TALER_TESTING_cmd_check_bank_empty ("check_bank_empty-10"),
- TALER_TESTING_cmd_end (),
-
/* pay abort */
CMD_TRANSFER_TO_EXCHANGE ("create-reserve-11",
"EUR:10.02"),
diff --git a/src/lib/testing_api_cmd_refund.c b/src/lib/testing_api_cmd_refund.c
@@ -237,8 +237,8 @@ refund_lookup_cb (void *cls,
&h_coin_pub);
GNUNET_assert (GNUNET_OK == GNUNET_CONTAINER_multihashmap_put
(map,
- &h_coin_pub,
- irefund_amount,
+ &h_coin_pub, // which
+ irefund_amount, // how much
GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY));
};
@@ -265,7 +265,7 @@ refund_lookup_cb (void *cls,
if ( NULL ==
( icoin_cmd = TALER_TESTING_interpreter_lookup_command
- (rls->is, icoin_reference)))
+ (rls->is, icoin_reference)) )
{
GNUNET_break (0);
TALER_LOG_ERROR ("Bad reference `%s'\n",
@@ -305,9 +305,9 @@ refund_lookup_cb (void *cls,
GNUNET_free (coin_reference_dup);
- if ( NULL ==
- ( increase_cmd = TALER_TESTING_interpreter_lookup_command
- (rls->is, rls->increase_reference)))
+ if (NULL ==
+ (increase_cmd = TALER_TESTING_interpreter_lookup_command
+ (rls->is, rls->increase_reference)))
TALER_TESTING_FAIL (rls->is);
if (GNUNET_OK != TALER_TESTING_get_trait_amount