summaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_merchant_get_tip.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-12-14 16:10:40 +0100
committerChristian Grothoff <christian@grothoff.org>2021-12-14 16:10:40 +0100
commitad5d54f48534ac0ad5bfd7f048bd7782e674a89b (patch)
tree4443e41c1aec412d82642b194aa3d837c9eb5cfd /src/testing/testing_api_cmd_merchant_get_tip.c
parent49e2e44b09dd845d0922c0acef5ff487b52bf26d (diff)
downloadmerchant-ad5d54f48534ac0ad5bfd7f048bd7782e674a89b.tar.gz
merchant-ad5d54f48534ac0ad5bfd7f048bd7782e674a89b.tar.bz2
merchant-ad5d54f48534ac0ad5bfd7f048bd7782e674a89b.zip
migration to protocol v11
Diffstat (limited to 'src/testing/testing_api_cmd_merchant_get_tip.c')
-rw-r--r--src/testing/testing_api_cmd_merchant_get_tip.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/src/testing/testing_api_cmd_merchant_get_tip.c b/src/testing/testing_api_cmd_merchant_get_tip.c
index 81be677d..6b247e75 100644
--- a/src/testing/testing_api_cmd_merchant_get_tip.c
+++ b/src/testing/testing_api_cmd_merchant_get_tip.c
@@ -94,7 +94,7 @@ merchant_get_tip_cb (void *cls,
const struct TALER_Amount *total_authorized,
const struct TALER_Amount *total_picked_up,
const char *reason,
- struct GNUNET_TIME_Absolute expiration,
+ struct GNUNET_TIME_Timestamp expiration,
const struct TALER_ReservePublicKeyP *reserve_pub,
unsigned int pickups_length,
const struct TALER_MERCHANT_PickupDetail pickups[])
@@ -108,8 +108,9 @@ merchant_get_tip_cb (void *cls,
gts->tip_reference);
gts->tgh = NULL;
- GNUNET_assert (GNUNET_OK == TALER_amount_set_zero (total_picked_up->currency,
- &expected_total_picked_up));
+ GNUNET_assert (GNUNET_OK ==
+ TALER_amount_set_zero (total_picked_up->currency,
+ &expected_total_picked_up));
if (gts->http_status != hr->http_status)
{
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
@@ -161,14 +162,16 @@ merchant_get_tip_cb (void *cls,
}
}
{
- const struct GNUNET_TIME_Absolute *tip_expiration;
+ const struct GNUNET_TIME_Timestamp *tip_expiration;
if (GNUNET_OK !=
- TALER_TESTING_get_trait_absolute_time (authorize_cmd,
- 0,
- &tip_expiration))
+ TALER_TESTING_get_trait_timestamp (authorize_cmd,
+ 0,
+ &tip_expiration))
TALER_TESTING_FAIL (gts->is);
- if (tip_expiration->abs_value_us != expiration.abs_value_us)
+ if (GNUNET_TIME_timestamp_cmp (*tip_expiration,
+ !=,
+ expiration))
{
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
"Tip authorized expiration does not match\n");