diff options
author | Christian Grothoff <christian@grothoff.org> | 2024-11-11 21:11:16 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2024-11-11 21:11:28 +0100 |
commit | 6e3197d2710de656cda8dcd9a92175fd083d0b9d (patch) | |
tree | 9c51fefdd7fe116f669be4f1bf72954a990c12f3 | |
parent | bbb7277a581193d6a335fe975c80a2bb75d8a6a7 (diff) |
fix test: init auditor and exchange DB before running test
-rw-r--r-- | src/testing/test_auditor_api_version.c | 37 |
1 files changed, 35 insertions, 2 deletions
diff --git a/src/testing/test_auditor_api_version.c b/src/testing/test_auditor_api_version.c index dcd542ad8..83ef969a0 100644 --- a/src/testing/test_auditor_api_version.c +++ b/src/testing/test_auditor_api_version.c @@ -146,6 +146,38 @@ main (int argc, NULL); proc = GNUNET_OS_start_process (GNUNET_OS_INHERIT_STD_ALL, NULL, NULL, NULL, + "taler-auditor-dbinit", + "taler-auditor-dbinit", + "-c", CONFIG_FILE, + "-L", "INFO", + NULL); + if (NULL == proc) + { + GNUNET_log ( + GNUNET_ERROR_TYPE_ERROR, + "Failed to run `taler-auditor-dbinit`, is your PATH correct?\n"); + return 77; + } + GNUNET_OS_process_wait (proc); + GNUNET_OS_process_destroy (proc); + proc = GNUNET_OS_start_process (GNUNET_OS_INHERIT_STD_ALL, + NULL, NULL, NULL, + "taler-exchange-dbinit", + "taler-exchange-dbinit", + "-c", CONFIG_FILE, + "-L", "INFO", + NULL); + if (NULL == proc) + { + GNUNET_log ( + GNUNET_ERROR_TYPE_ERROR, + "Failed to run `taler-auditor-dbinit`, is your PATH correct?\n"); + return 77; + } + GNUNET_OS_process_wait (proc); + GNUNET_OS_process_destroy (proc); + proc = GNUNET_OS_start_process (GNUNET_OS_INHERIT_STD_ALL, + NULL, NULL, NULL, "taler-auditor-httpd", "taler-auditor-httpd", "-c", CONFIG_FILE, @@ -153,8 +185,9 @@ main (int argc, NULL); if (NULL == proc) { - GNUNET_log (GNUNET_ERROR_TYPE_ERROR, - "Failed to run `taler-auditor-httpd`, is your PATH correct?\n"); + GNUNET_log ( + GNUNET_ERROR_TYPE_ERROR, + "Failed to run `taler-auditor-httpd`, is your PATH correct?\n"); return 77; } global_ret = TALER_TESTING_wait_httpd_ready ("http://localhost:8083/"); |