aboutsummaryrefslogtreecommitdiff
path: root/src/testing/testing_api_traits.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-06-22 20:26:34 +0200
committerChristian Grothoff <christian@grothoff.org>2023-06-22 20:26:34 +0200
commit7bb95475994504fa56902159be4f4789a3793a38 (patch)
treeb13ca4cf313de4eba6bdd7f82e36228c82f958df /src/testing/testing_api_traits.c
parent22d5b9fc3a304b89c05e4493d8bb10cef6a38134 (diff)
downloadexchange-7bb95475994504fa56902159be4f4789a3793a38.tar.xz
more API cleanup
Diffstat (limited to 'src/testing/testing_api_traits.c')
-rw-r--r--src/testing/testing_api_traits.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/testing/testing_api_traits.c b/src/testing/testing_api_traits.c
index d84e2c37e..27eef5a5b 100644
--- a/src/testing/testing_api_traits.c
+++ b/src/testing/testing_api_traits.c
@@ -102,4 +102,31 @@ TALER_TESTING_get_exchange (struct TALER_TESTING_Interpreter *is)
}
+const char *
+TALER_TESTING_get_exchange_url (struct TALER_TESTING_Interpreter *is)
+{
+ const char *exchange_url;
+ const struct TALER_TESTING_Command *exchange_cmd;
+
+ exchange_cmd
+ = TALER_TESTING_interpreter_get_command (is,
+ "exchange");
+ if (NULL == exchange_cmd)
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return NULL;
+ }
+ if (GNUNET_OK !=
+ TALER_TESTING_get_trait_exchange_url (exchange_cmd,
+ &exchange_url))
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return NULL;
+ }
+ return exchange_url;
+}
+
+
/* end of testing_api_traits.c */