From dabcf7f42e4d15fa86f54e1dbf300c19a9adcb6e Mon Sep 17 00:00:00 2001 From: Marcello Stanisci Date: Mon, 21 Jan 2019 20:07:26 +0100 Subject: Logically grouping test commands. --- src/lib/test_exchange_api_keys_cherry_picking.conf | 3 -- .../test_exchange_api_keys_cherry_picking_new.c | 43 ++++++++++++---------- 2 files changed, 23 insertions(+), 23 deletions(-) (limited to 'src') diff --git a/src/lib/test_exchange_api_keys_cherry_picking.conf b/src/lib/test_exchange_api_keys_cherry_picking.conf index 8d5585e3a..e65d1e009 100644 --- a/src/lib/test_exchange_api_keys_cherry_picking.conf +++ b/src/lib/test_exchange_api_keys_cherry_picking.conf @@ -83,9 +83,6 @@ ENABLE_DEBIT = YES ENABLE_CREDIT = YES - - - [fees-x-taler-bank] # Fees for the forseeable future... # If you see this after 2017, update to match the next 10 years... diff --git a/src/lib/test_exchange_api_keys_cherry_picking_new.c b/src/lib/test_exchange_api_keys_cherry_picking_new.c index 45222a66c..c1dde0009 100644 --- a/src/lib/test_exchange_api_keys_cherry_picking_new.c +++ b/src/lib/test_exchange_api_keys_cherry_picking_new.c @@ -63,7 +63,6 @@ static char *exchange_url; */ static char *auditor_url; - /** * Main function that will tell the interpreter what commands to * run. @@ -109,31 +108,24 @@ run (void *cls, TALER_TESTING_cmd_sleep ("sleep-serialization", 3), - /** - * XXX. - * - * Current bug: this CMD here uses the "reconnect cert_cb", - * that has its 'consumed' field already set to GNUNET_YES. - * This way, there is no way to pass control to the next - * CMD making therefore the interpreter stuck. - * - * Doable solution: adapt the global "cert_cb" to handle - * "reconnect situations", or even provide some method to - * switch the 'consumed' field back to GNUNET_NO. + * Why keys number decrease? */ TALER_TESTING_cmd_check_keys ("check-freshest-keys", - 4, - 10), + 8, + 8), TALER_TESTING_cmd_wire ("verify-/wire-with-fresh-keys", - "x-taler-bank", - NULL, - MHD_HTTP_OK), - TALER_TESTING_cmd_end () + "x-taler-bank", + NULL, + MHD_HTTP_OK), + + TALER_TESTING_cmd_end (), + }; - struct TALER_TESTING_Command commands[] = { + struct TALER_TESTING_Command ordinary_cherry_pick[] = { + /* Trigger keys reloading from disk. */ TALER_TESTING_cmd_signal ("signal-reaction-1", is->exchanged, @@ -179,9 +171,18 @@ run (void *cls, TALER_TESTING_cmd_check_keys ("check-keys-3", 3, 8), + TALER_TESTING_cmd_end () + }; + + + struct TALER_TESTING_Command commands[] = { + + TALER_TESTING_cmd_batch ("ordinary-cherry-pick", + ordinary_cherry_pick), TALER_TESTING_cmd_batch ("keys-serialization", keys_serialization), + TALER_TESTING_cmd_end () }; @@ -198,7 +199,9 @@ main (int argc, unsetenv ("XDG_DATA_HOME"); unsetenv ("XDG_CONFIG_HOME"); GNUNET_log_setup ("test-exchange-api-cherry-picking-new", - "DEBUG", NULL); + "DEBUG", + NULL); + TALER_TESTING_cleanup_files (CONFIG_FILE); /* @helpers. Run keyup, create tables, ... Note: it * fetches the port number from config in order to see -- cgit v1.2.3