aboutsummaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_purse_deposit.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-05-23 15:29:35 +0200
committerChristian Grothoff <christian@grothoff.org>2022-05-23 15:29:35 +0200
commita509a91f924cad3b5f0336f78e5c80e3621ad52b (patch)
tree404bfdbbd566478a158aa60e957bff37bc16364e /src/testing/testing_api_cmd_purse_deposit.c
parentcdd2930a9951a552d221b8a8b8e9c0df35ad8be2 (diff)
downloadexchange-a509a91f924cad3b5f0336f78e5c80e3621ad52b.tar.xz
-more reserve history fixes
Diffstat (limited to 'src/testing/testing_api_cmd_purse_deposit.c')
-rw-r--r--src/testing/testing_api_cmd_purse_deposit.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/testing/testing_api_cmd_purse_deposit.c b/src/testing/testing_api_cmd_purse_deposit.c
index 86ed1b185..1c6dcdd9b 100644
--- a/src/testing/testing_api_cmd_purse_deposit.c
+++ b/src/testing/testing_api_cmd_purse_deposit.c
@@ -159,6 +159,7 @@ deposit_cb (void *cls,
const struct TALER_ReserveSignatureP *reserve_sig;
const struct TALER_ReservePublicKeyP *reserve_pub;
const struct GNUNET_TIME_Timestamp *merge_timestamp;
+ const struct TALER_PurseMergePublicKeyP *merge_pub;
purse_cmd = TALER_TESTING_interpreter_lookup_command (ds->is,
ds->purse_ref);
@@ -179,6 +180,14 @@ deposit_cb (void *cls,
TALER_TESTING_interpreter_fail (ds->is);
return;
}
+ if (GNUNET_OK !=
+ TALER_TESTING_get_trait_merge_pub (purse_cmd,
+ &merge_pub))
+ {
+ GNUNET_break (0);
+ TALER_TESTING_interpreter_fail (ds->is);
+ return;
+ }
ds->reserve_pub = *reserve_pub;
if (GNUNET_OK !=
TALER_TESTING_get_trait_timestamp (purse_cmd,
@@ -213,7 +222,9 @@ deposit_cb (void *cls,
ds->reserve_history.details.merge_details.h_contract_terms
= dr->details.success.h_contract_terms;
ds->reserve_history.details.merge_details.merge_pub
- = dr->details.success.merge_pub;
+ = *merge_pub;
+ ds->reserve_history.details.merge_details.purse_pub
+ = ds->purse_pub;
ds->reserve_history.details.merge_details.reserve_sig
= *reserve_sig;
ds->reserve_history.details.merge_details.merge_timestamp