summaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_kyc_wallet_get.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-06-22 22:05:34 +0200
committerChristian Grothoff <christian@grothoff.org>2023-06-22 22:05:34 +0200
commit720783b66a08a14624f30e8063daf64d25ce3e4c (patch)
tree24ae1feb57b363e18f279f9907e2b8cd37f87a62 /src/testing/testing_api_cmd_kyc_wallet_get.c
parent999dae7c5d0c37473e486fa38816a3f35c42dba9 (diff)
downloadexchange-720783b66a08a14624f30e8063daf64d25ce3e4c.tar.gz
exchange-720783b66a08a14624f30e8063daf64d25ce3e4c.tar.bz2
exchange-720783b66a08a14624f30e8063daf64d25ce3e4c.zip
-more exchange API atomization
Diffstat (limited to 'src/testing/testing_api_cmd_kyc_wallet_get.c')
-rw-r--r--src/testing/testing_api_cmd_kyc_wallet_get.c25
1 files changed, 15 insertions, 10 deletions
diff --git a/src/testing/testing_api_cmd_kyc_wallet_get.c b/src/testing/testing_api_cmd_kyc_wallet_get.c
index 5f6eaeb4c..fa6edab20 100644
--- a/src/testing/testing_api_cmd_kyc_wallet_get.c
+++ b/src/testing/testing_api_cmd_kyc_wallet_get.c
@@ -147,13 +147,16 @@ wallet_kyc_run (void *cls,
struct TALER_TESTING_Interpreter *is)
{
struct KycWalletGetState *kwg = cls;
- struct TALER_EXCHANGE_Handle *exchange
- = TALER_TESTING_get_exchange (is);
+ const char *exchange_url;
kwg->cmd = cmd;
- if (NULL == exchange)
- return;
kwg->is = is;
+ exchange_url = TALER_TESTING_get_exchange_url (is);
+ if (NULL == exchange_url)
+ {
+ GNUNET_break (0);
+ return;
+ }
if (NULL != kwg->reserve_reference)
{
const struct TALER_TESTING_Command *res_cmd;
@@ -185,13 +188,15 @@ wallet_kyc_run (void *cls,
GNUNET_CRYPTO_eddsa_key_get_public (&kwg->reserve_priv.eddsa_priv,
&kwg->reserve_pub.eddsa_pub);
kwg->reserve_payto_uri
- = TALER_reserve_make_payto (TALER_EXCHANGE_get_base_url (exchange),
+ = TALER_reserve_make_payto (exchange_url,
&kwg->reserve_pub);
- kwg->kwh = TALER_EXCHANGE_kyc_wallet (exchange,
- &kwg->reserve_priv,
- &kwg->balance,
- &wallet_kyc_cb,
- kwg);
+ kwg->kwh = TALER_EXCHANGE_kyc_wallet (
+ TALER_TESTING_interpreter_get_context (is),
+ exchange_url,
+ &kwg->reserve_priv,
+ &kwg->balance,
+ &wallet_kyc_cb,
+ kwg);
GNUNET_assert (NULL != kwg->kwh);
}