summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMarcello Stanisci <stanisci.m@gmail.com>2018-05-17 09:36:30 +0200
committerMarcello Stanisci <stanisci.m@gmail.com>2018-05-17 09:36:30 +0200
commit7a1bb2b4c8ea579f0745f9471922098a9daffa38 (patch)
treeea251656e13803f3eb025613713f33abe79d26c0 /src
parent8ec523afbba274a0979eb2c0696c30c3e13fc919 (diff)
downloadexchange-7a1bb2b4c8ea579f0745f9471922098a9daffa38.tar.gz
exchange-7a1bb2b4c8ea579f0745f9471922098a9daffa38.tar.bz2
exchange-7a1bb2b4c8ea579f0745f9471922098a9daffa38.zip
prepare ground to refund twist-tests.
Diffstat (limited to 'src')
-rw-r--r--src/exchange-lib/test_exchange_api_twisted.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/exchange-lib/test_exchange_api_twisted.c b/src/exchange-lib/test_exchange_api_twisted.c
index 762f124b3..11533e2ef 100644
--- a/src/exchange-lib/test_exchange_api_twisted.c
+++ b/src/exchange-lib/test_exchange_api_twisted.c
@@ -198,6 +198,40 @@ run (void *cls,
"refresh-melt",
MHD_HTTP_CONFLICT),
+ /* Next chunk, refund conflicts (contract hash missmatch,
+ original deposit does not exist,
+ currency missmatch);
+
+ 'refund_transaction()' has many of the relevant cases;
+ */
+
+
+ CMD_TRANSFER_TO_EXCHANGE
+ ("create-reserve-r1",
+ "EUR:5.01"),
+ CMD_EXEC_WIREWATCH
+ ("wirewatch-r1"),
+ TALER_TESTING_cmd_withdraw_amount
+ ("withdraw-coin-r1",
+ is->exchange,
+ "create-reserve-r1",
+ "EUR:5",
+ MHD_HTTP_OK),
+
+ TALER_TESTING_cmd_deposit
+ ("deposit-refund-1",
+ is->exchange,
+ "withdraw-coin-r1",
+ 0,
+ TALER_TESTING_make_wire_details
+ (42,
+ fakebank_url),
+ "{\"items\":[{\"name\":\"ice cream\","
+ "\"value\":\"EUR:5\"}]}",
+ GNUNET_TIME_UNIT_MINUTES,
+ "EUR:5",
+ MHD_HTTP_OK),
+
TALER_TESTING_cmd_end ()
};