From 571d43cef3732ed6f491d91a9e767a80008edeb1 Mon Sep 17 00:00:00 2001 From: Özgür Kesim Date: Thu, 27 Jul 2023 23:57:07 +0200 Subject: [WiP] added TALER_AMOUNT type to Postgres - first in age_withdraw - Added a type TALER_AMOUNT (val INT8, frac INT4) to Postgres. - Added PLSQL functions/procedures - amount_normalize(a) - amount_add(a, b) - amount_left_minus_right(l, r, diff, ok bool) - Added PQ-helper functions - TALER_PQ_query_param_amount_tuple() - TALER_PQ_result_spec_amount_tuple() - In table 'age_withdraw', changed fields 'amount_with_fee_val' and '..._frac' into single field 'amount_with_fee' be of type TALER_AMOUNT - Changed functions/stored procedures 'do_age_withdraw' and 'get_age_withdraw' to use new APIs. => make check runs through without errors, age-withdraw and -reveal test passes. --- src/exchangedb/test_exchangedb.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/exchangedb/test_exchangedb.c') diff --git a/src/exchangedb/test_exchangedb.c b/src/exchangedb/test_exchangedb.c index ac3735b2d..36f51120a 100644 --- a/src/exchangedb/test_exchangedb.c +++ b/src/exchangedb/test_exchangedb.c @@ -1421,6 +1421,8 @@ run (void *cls) bool found; bool nonce_ok; bool balance_ok; + bool age_ok; + uint16_t maximum_age; uint64_t ruuid; FAILIF (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT != @@ -1428,9 +1430,12 @@ run (void *cls) NULL, &cbc, now, + false, &found, &balance_ok, &nonce_ok, + &age_ok, + &maximum_age, &ruuid)); GNUNET_assert (found); GNUNET_assert (nonce_ok); -- cgit v1.2.3