gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-merchant] branch master updated: continue 2021-05-27 "implement s


From: gnunet
Subject: [taler-merchant] branch master updated: continue 2021-05-27 "implement specification update #6891"
Date: Fri, 28 May 2021 07:32:05 +0200

This is an automated email from the git hooks/post-receive script.

ttn pushed a commit to branch master
in repository merchant.

The following commit(s) were added to refs/heads/master by this push:
     new c25419a1 continue 2021-05-27 "implement specification update #6891"
c25419a1 is described below

commit c25419a17238ce074979f6a69b2b6de55020a930
Author: Thien-Thi Nguyen <ttn@gnuvola.org>
AuthorDate: Thu May 27 14:23:14 2021 -0400

    continue 2021-05-27 "implement specification update #6891"
    
    This change continues 5dea2c74a16191d269c8fc7beead55c2683c887a:
    (ReserveData): Add member ‘payto_uri’.
    (pre_test_tips): Initialize ‘cls->reserve.payto_uri’ to a plausible value.
    (test_insert_reserve): Pass ‘reserve->payto_uri’ to 
‘plugin->insert_reserve’.
    (lookup_reserve_cb):Add to arglist ‘exchange_url’, ‘payto_uri’.
    Add FIXME re ‘exchange_url’, ‘payto_uri’.
---
 src/backenddb/test_merchantdb.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/src/backenddb/test_merchantdb.c b/src/backenddb/test_merchantdb.c
index 237bd18e..d8229951 100644
--- a/src/backenddb/test_merchantdb.c
+++ b/src/backenddb/test_merchantdb.c
@@ -4376,6 +4376,11 @@ struct ReserveData
    */
   const char *exchange_url;
 
+  /**
+   * The payto URI
+   */
+  const char *payto_uri;
+
   /**
    * The expiration date
    */
@@ -4402,6 +4407,7 @@ test_insert_reserve (const struct InstanceData *instance,
                                                  &reserve->reserve_priv,
                                                  &reserve->reserve_pub,
                                                  reserve->exchange_url,
+                                                 reserve->payto_uri,
                                                  &reserve->initial_amount,
                                                  reserve->expiration),
                          "Insert reserve failed\n");
@@ -4448,6 +4454,8 @@ struct TestLookupReserve_Closure
  * @param committed_amount total of tips that the merchant committed to, but 
that were not
  *           picked up yet
  * @param active true if the reserve is still active (we have the private key)
+ * @param exchange_url base URL of the exchange hosting the reserve, NULL if 
not @a active
+ * @param payto_uri URI to use to fund the reserve, NULL if not @a active
  * @param tips_length length of the @a tips array
  * @param tips information about the tips created by this reserve
  *
@@ -4462,6 +4470,8 @@ lookup_reserve_cb (void *cls,
                    const struct TALER_Amount *picked_up_amount,
                    const struct TALER_Amount *committed_amount,
                    bool active,
+                   const char *exchange_url,
+                   const char *payto_uri,
                    unsigned int tips_length,
                    const struct TALER_MERCHANTDB_TipDetails *tips)
 {
@@ -4481,6 +4491,7 @@ lookup_reserve_cb (void *cls,
     cmp->result_matches = 1;
     return;
   }
+  /* FIXME: What about ‘exchange_url’ and ‘payto_uri’?  --ttn  */
   memset (tip_cmp_results, 0, sizeof (unsigned int) * tips_length);
   for (unsigned int i = 0; tips_length > i; ++i)
   {
@@ -5301,6 +5312,7 @@ pre_test_tips (struct TestTips_Closure *cls)
                  TALER_string_to_amount ("EUR:99.99",
                                          &cls->reserve.initial_amount));
   cls->reserve.exchange_url = "exch-url";
+  cls->reserve.payto_uri = "payto://other-uri";
   cls->reserve.expiration =
     GNUNET_TIME_absolute_add (GNUNET_TIME_absolute_get (),
                               GNUNET_TIME_UNIT_WEEKS);

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]