aboutsummaryrefslogtreecommitdiff
path: root/src/lib/testing_api_cmd_track.c
diff options
context:
space:
mode:
authorMarcello Stanisci <stanisci.m@gmail.com>2019-06-03 18:42:07 +0200
committerMarcello Stanisci <stanisci.m@gmail.com>2019-06-03 18:42:07 +0200
commit4f17b17fe35153daaa40a97a952d5da58fa3a18a (patch)
tree1fc075f20ee89dbc98e048d3a0f156873300f5b0 /src/lib/testing_api_cmd_track.c
parent60549a69c794106e1d1ceae249488542c53b68c3 (diff)
Moving checks where they belong.
Diffstat (limited to 'src/lib/testing_api_cmd_track.c')
-rw-r--r--src/lib/testing_api_cmd_track.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/src/lib/testing_api_cmd_track.c b/src/lib/testing_api_cmd_track.c
index 4a054144d..1c2130839 100644
--- a/src/lib/testing_api_cmd_track.c
+++ b/src/lib/testing_api_cmd_track.c
@@ -523,21 +523,23 @@ track_transfer_cb
TALER_TESTING_interpreter_fail (is);
return;
}
- if (NULL == tts->expected_total_amount)
- {
- GNUNET_break (0);
- TALER_TESTING_interpreter_fail (is);
- return;
- }
- if (NULL == tts->expected_wire_fee)
- {
- GNUNET_break (0);
- TALER_TESTING_interpreter_fail (is);
- return;
- }
+
switch (http_status)
{
case MHD_HTTP_OK:
+ if (NULL == tts->expected_total_amount)
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return;
+ }
+ if (NULL == tts->expected_wire_fee)
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (is);
+ return;
+ }
+
if (GNUNET_OK !=
TALER_string_to_amount (tts->expected_total_amount,
&expected_amount))