implement test mode in taler-exchange-transfer

This commit is contained in:
Christian Grothoff 2020-03-13 15:19:47 +01:00
parent 9c20b62eb9
commit e05ce36f30
No known key found for this signature in database
GPG Key ID: 939E6BE1E29FC3CC
2 changed files with 11 additions and 4 deletions

View File

@ -447,9 +447,16 @@ run_transfers (void *cls)
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
"No more pending wire transfers, going idle\n");
GNUNET_assert (NULL == task);
task = GNUNET_SCHEDULER_add_delayed (aggregator_idle_sleep_interval,
&run_transfers,
NULL);
if (GNUNET_YES == test_mode)
{
GNUNET_SCHEDULER_shutdown ();
}
else
{
task = GNUNET_SCHEDULER_add_delayed (aggregator_idle_sleep_interval,
&run_transfers,
NULL);
}
return;
case GNUNET_DB_STATUS_SUCCESS_ONE_RESULT:
/* should be impossible */

View File

@ -39,7 +39,7 @@ PREFIX=
#PREFIX="valgrind --leak-check=yes --track-fds=yes --error-exitcode=1 --log-file=valgrind.%p"
# Setup keys.
taler-exchange-keyup -c test_taler_exchange_httpd.conf
# Setup database (just to be sure)
# Setup database
taler-exchange-dbinit -c test_taler_exchange_httpd.conf &> /dev/null
# Only log hard errors, we expect lots of warnings...
export GNUNET_FORCE_LOG=";;;;ERROR"