summaryrefslogtreecommitdiff
path: root/src/testing
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-04-10 13:51:36 +0200
committerChristian Grothoff <christian@grothoff.org>2023-04-10 13:51:36 +0200
commit122c926493f2a22820f280fd2546e495e6b5874d (patch)
tree4bcfc1f727c6580ea2b560701c21b67d9473eded /src/testing
parent27c9fef5ea725ad9b80acbf7f99f6fa6486d59c7 (diff)
downloadexchange-122c926493f2a22820f280fd2546e495e6b5874d.tar.gz
exchange-122c926493f2a22820f280fd2546e495e6b5874d.tar.bz2
exchange-122c926493f2a22820f280fd2546e495e6b5874d.zip
avoid crashing, fail test instead
Diffstat (limited to 'src/testing')
-rw-r--r--src/testing/testing_api_cmd_take_aml_decision.c22
1 files changed, 16 insertions, 6 deletions
diff --git a/src/testing/testing_api_cmd_take_aml_decision.c b/src/testing/testing_api_cmd_take_aml_decision.c
index 871cdb712..21ba9af6f 100644
--- a/src/testing/testing_api_cmd_take_aml_decision.c
+++ b/src/testing/testing_api_cmd_take_aml_decision.c
@@ -151,9 +151,14 @@ take_aml_decision_run (void *cls,
TALER_TESTING_interpreter_fail (is);
return;
}
- GNUNET_assert (GNUNET_OK ==
- TALER_TESTING_get_trait_h_payto (ref,
- &h_payto));
+ if (GNUNET_OK !=
+ TALER_TESTING_get_trait_h_payto (ref,
+ &h_payto))
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return;
+ }
ref = TALER_TESTING_interpreter_lookup_command (is,
ds->officer_ref_cmd);
if (NULL == ref)
@@ -162,9 +167,14 @@ take_aml_decision_run (void *cls,
TALER_TESTING_interpreter_fail (is);
return;
}
- GNUNET_assert (GNUNET_OK ==
- TALER_TESTING_get_trait_officer_priv (ref,
- &officer_priv));
+ if (GNUNET_OK !=
+ TALER_TESTING_get_trait_officer_priv (ref,
+ &officer_priv))
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return;
+ }
ds->h_payto = *h_payto;
if (NULL != ds->kyc_requirement)
{