merchant

Merchant backend to process payments, run by merchants
Log | Files | Refs | Submodules | README | LICENSE

commit 9ebfdb165ded86a47903559e18622c5afc999a5d
parent 9259ddb29aff66210562f064a03532d24ec2489b
Author: Marcello Stanisci <stanisci.m@gmail.com>
Date:   Thu, 10 May 2018 20:01:20 +0200

Paygen /track preparation.

Inserting a /proposal + /pay pair so as to
prepare the preliminary data to use /track CMDs on.

Diffstat:
Msrc/merchant-tools/taler-merchant-generate-payments_new.c | 36++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+), 0 deletions(-)

diff --git a/src/merchant-tools/taler-merchant-generate-payments_new.c b/src/merchant-tools/taler-merchant-generate-payments_new.c @@ -175,6 +175,42 @@ run (void *cls, FIRST_INSTRUCTION, &payments_number), + /* Next proposal-pay cycle will be used by /track CMDs + * and so it will not have to be looped over, only /track + * CMDs will have to. */ + + TALER_TESTING_cmd_proposal + ("create-proposal-2", + merchant_url, + is->ctx, + MHD_HTTP_OK, + "{\"max_fee\":\ + {\"currency\":\"USD\",\ + \"value\":0,\ + \"fraction\":50000000},\ + \"refund_deadline\":\"\\/Date(0)\\/\",\ + \"pay_deadline\":\"\\/Date(99999999999)\\/\",\ + \"amount\":\ + {\"currency\":\"USD\",\ + \"value\":5,\ + \"fraction\":0},\ + \"summary\": \"merchant-lib testcase\",\ + \"fulfillment_url\": \"https://example.com/\",\ + \"products\": [ {\"description\":\"ice track cream\",\ + \"value\":\"{USD:5}\"} ] }", + NULL), + + TALER_TESTING_cmd_pay + ("deposit-simple-2", + merchant_url, + is->ctx, + MHD_HTTP_OK, + "create-proposal-2", + "withdraw-coin-2", + "USD:5", + "USD:4.99", + "USD:0.01"), + TALER_TESTING_cmd_end () };