gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [taler-merchant] branch master updated (a54daf3 -> b314ea0)


From: gnunet
Subject: [GNUnet-SVN] [taler-merchant] branch master updated (a54daf3 -> b314ea0)
Date: Tue, 27 Mar 2018 12:21:33 +0200

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

marcello pushed a change to branch master
in repository merchant.

    from a54daf3  fix tipping test aftermath.
     new f73cf1f  test non 200 response code from /check-payment.
     new 5ac75e2  check against bad payment_redirect_url.
     new ed2f256  - verbose
     new 1247a3e  testing /check-payment.
     new b314ea0  remove debug statement.

The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 src/lib/test_merchant_api_twisted.c | 64 +++++++++++++++++++++++++++++++++++++
 1 file changed, 64 insertions(+)

diff --git a/src/lib/test_merchant_api_twisted.c 
b/src/lib/test_merchant_api_twisted.c
index 8bb9d07..c2b9a67 100644
--- a/src/lib/test_merchant_api_twisted.c
+++ b/src/lib/test_merchant_api_twisted.c
@@ -182,6 +182,68 @@ run (void *cls,
 
   struct TALER_TESTING_Command commands[] = {
 
+  /**** Covering /check-payment ****/
+
+    TALER_TESTING_cmd_proposal
+      ("proposal-for-check-payment",
+       twister_merchant_url,
+       is->ctx,
+       MHD_HTTP_OK,
+       "{\"max_fee\":\
+          {\"currency\":\"EUR\",\
+           \"value\":0,\
+           \"fraction\":50000000},\
+        \"order_id\":\"fail-check-payment-1\",\
+        \"refund_deadline\":\"\\/Date(0)\\/\",\
+        \"pay_deadline\":\"\\/Date(99999999999)\\/\",\
+        \"fulfillment_url\": \"https://example.com/\",\
+        \"amount\":\
+          {\"currency\":\"EUR\",\
+           \"value\":2,\
+           \"fraction\":0},\
+        \"summary\": \"merchant-lib testcase\",\
+        \"products\": [ {\"description\":\"ice cream\",\
+                         \"value\":\"{EUR:3}\"} ] }",
+       NULL),
+
+    /* Need any response code != 200.  */
+    TALER_TESTING_cmd_hack_response_code
+      ("non-200-response-code",
+       PROXY_MERCHANT_CONFIG_FILE,
+       MHD_HTTP_MULTIPLE_CHOICES),
+
+    TALER_TESTING_cmd_check_payment
+      ("check-payment-fail",
+       twister_merchant_url,
+       is->ctx,
+       MHD_HTTP_MULTIPLE_CHOICES,
+       "proposal-for-check-payment",
+       GNUNET_SYSERR), // any response != 200 gives "syserr"
+
+    TALER_TESTING_cmd_delete_object ("hack-check-payment-0",
+                                     PROXY_MERCHANT_CONFIG_FILE,
+                                     "payment_redirect_url"),
+    TALER_TESTING_cmd_check_payment
+      ("check-payment-fail-invalid",
+       twister_merchant_url,
+       is->ctx,
+       0,
+       "proposal-for-check-payment",
+       GNUNET_SYSERR),
+
+    TALER_TESTING_cmd_modify_object
+      ("paid-true-for-unpaid",
+       PROXY_MERCHANT_CONFIG_FILE,
+       "paid",
+       "true"),
+
+    TALER_TESTING_cmd_check_payment
+      ("check-payment-fail-invalid-0",
+       twister_merchant_url,
+       is->ctx,
+       0,
+       "proposal-for-check-payment",
+       GNUNET_SYSERR),
 
   /**** Covering /proposal lib ****/
 
@@ -398,6 +460,8 @@ run (void *cls,
                                10), // nrows
 
 
+    /***** Test transactions tracking *****/
+
     /**
      * Move money to the exchange's bank account.
      */

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

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