diff options
author | Christian Grothoff <christian@grothoff.org> | 2017-07-21 22:22:01 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2017-07-21 23:19:49 +0200 |
commit | 759f073fb18a9f6e8f1565dafe42ed74d0ee6ded (patch) | |
tree | e070f3e0b27cff4d3710e9c83aaec26bd9db692a | |
parent | c3b2fba56aa5a72b9e075d9725c746683109be17 (diff) | |
download | merchant-759f073fb18a9f6e8f1565dafe42ed74d0ee6ded.tar.gz merchant-759f073fb18a9f6e8f1565dafe42ed74d0ee6ded.tar.bz2 merchant-759f073fb18a9f6e8f1565dafe42ed74d0ee6ded.zip |
fix merchant_api_track_transfer to actually pass wire method to service
-rw-r--r-- | src/lib/merchant_api_track_transfer.c | 2 | ||||
-rw-r--r-- | src/lib/test_merchant_api.c | 13 |
2 files changed, 10 insertions, 5 deletions
diff --git a/src/lib/merchant_api_track_transfer.c b/src/lib/merchant_api_track_transfer.c index f3a35b5d..660d4e1e 100644 --- a/src/lib/merchant_api_track_transfer.c +++ b/src/lib/merchant_api_track_transfer.c @@ -248,7 +248,7 @@ TALER_MERCHANT_track_transfer (struct GNUNET_CURL_Context *ctx, base = MAH_path_to_url_ (backend_uri, "/track/transfer"); GNUNET_asprintf (&tdo->url, - "%s?wtid=%s&exchange=%s&instance=%s&wire_method", + "%s?wtid=%s&exchange=%s&instance=%s&wire_method=%s", base, wtid_str, exchange_uri, diff --git a/src/lib/test_merchant_api.c b/src/lib/test_merchant_api.c index 441194d2..6f232094 100644 --- a/src/lib/test_merchant_api.c +++ b/src/lib/test_merchant_api.c @@ -2490,6 +2490,7 @@ run (void *cls) .details.reserve_status.reserve_reference = "create-reserve-1", .details.reserve_status.expected_balance = "EUR:0" }, + /* Create proposal */ { .oc = OC_PROPOSAL, .label = "create-proposal-1", @@ -2501,7 +2502,7 @@ run (void *cls) \"fraction\":50000000},\ \"order_id\":\"1\",\ \"refund_deadline\":\"\\/Date(0)\\/\",\ - \"pay_deadline\":\"\\/Date(9999999999)\\/\",\ + \"pay_deadline\":\"\\/Date(99999999999)\\/\",\ \"amount\":\ {\"currency\":\"EUR\",\ \"value\":5,\ @@ -2510,6 +2511,8 @@ run (void *cls) \"products\":\ [ {\"description\":\"ice cream\",\ \"value\":\"{EUR:5}\"} ] }"}, + + /* execute simple payment */ { .oc = OC_PAY, .label = "deposit-simple", .expected_response_code = MHD_HTTP_OK, @@ -2517,6 +2520,7 @@ run (void *cls) .details.pay.coin_ref = "withdraw-coin-1;withdraw-coin-2", .details.pay.amount_with_fee = "EUR:5", .details.pay.amount_without_fee = "EUR:4.99" }, + /* Try to replay payment reusing coin */ { .oc = OC_PAY, .label = "replay-simple", @@ -2525,6 +2529,7 @@ run (void *cls) .details.pay.coin_ref = "withdraw-coin-1", .details.pay.amount_with_fee = "EUR:5", .details.pay.amount_without_fee = "EUR:4.99" }, + /* Create another contract */ { .oc = OC_PROPOSAL, .label = "create-proposal-2", @@ -2556,6 +2561,7 @@ run (void *cls) .details.pay.coin_ref = "withdraw-coin-1", .details.pay.amount_with_fee = "EUR:5", .details.pay.amount_without_fee = "EUR:4.99" }, + /* Fill second reserve with EUR:1 */ { .oc = OC_ADMIN_ADD_INCOMING, .label = "create-reserve-2", @@ -2603,13 +2609,12 @@ run (void *cls) /* Check nothing happened on the bank side so far */ { .oc = OC_CHECK_BANK_TRANSFERS_EMPTY, .label = "check_bank_empty" }, - - + /* Run transfers. */ { .oc = OC_RUN_AGGREGATOR, .label = "run-aggregator" }, - /* Obtain WTID of the transfer */ + /* Obtain WTID of the transfer generated by "deposit-simple" */ { .oc = OC_CHECK_BANK_TRANSFER, .label = "check_bank_transfer-498c", .details.check_bank_transfer.amount = "EUR:4.98", |