[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-merchant] 02/02: adding test creating a reserve with invalid curr
From: |
gnunet |
Subject: |
[taler-merchant] 02/02: adding test creating a reserve with invalid currency |
Date: |
Fri, 28 May 2021 18:03:20 +0200 |
This is an automated email from the git hooks/post-receive script.
sebasjm pushed a commit to branch master
in repository merchant.
commit a91527bb88e96bdc3023bb0a4fadf637eef2df5e
Author: Sebastian <sebasjm@gmail.com>
AuthorDate: Fri May 28 13:02:37 2021 -0300
adding test creating a reserve with invalid currency
---
src/testing/test_merchant_reserve_creation.sh | 30 +++++++++++++--------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/testing/test_merchant_reserve_creation.sh
b/src/testing/test_merchant_reserve_creation.sh
index 2bb4b8d1..4dd12926 100755
--- a/src/testing/test_merchant_reserve_creation.sh
+++ b/src/testing/test_merchant_reserve_creation.sh
@@ -20,21 +20,6 @@ fi
echo OK
-# echo -n "trying to create invalid reserve ..."
-
-# STATUS=$(curl 'http://localhost:9966/instances/default/private/reserves' \
-# -d
'{"initial_balance":"INVALID:2","exchange_url":"'$EXCHANGE_URL'","wire_method":"x-taler-bank"}'
\
-# -w "%{http_code}" -s -o $LAST_RESPONSE)
-
-# if [ "$STATUS" != "400" ]
-# then
-# echo 'should respond invalid, bad currency. got:' $STATUS
-# exit 1
-# fi
-
-# echo "FAILED (which is ok)"
-
-
echo -n "creating reserve ..."
STATUS=$(curl 'http://localhost:9966/instances/default/private/reserves' \
@@ -153,6 +138,21 @@ fi
echo OK
+echo -n "trying to create invalid reserve ..."
+
+STATUS=$(curl 'http://localhost:9966/instances/default/private/reserves' \
+ -d
'{"initial_balance":"INVALID:2","exchange_url":"'$EXCHANGE_URL'","wire_method":"x-taler-bank"}'
\
+ -w "%{http_code}" -s -o $LAST_RESPONSE)
+
+if [ "$STATUS" != "400" ]
+then
+ echo 'should respond invalid, bad currency. got:' $STATUS
+ exit 1
+fi
+
+echo "FAILED (which is ok)"
+
+
exit 0
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.