summaryrefslogtreecommitdiff
path: root/src/testing/test_merchant_instance_response.sh
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2024-02-06 00:12:10 +0100
committerChristian Grothoff <christian@grothoff.org>2024-02-06 00:12:10 +0100
commite51192f0e708670b19acfb3fc1c969f1702a334c (patch)
treeb8262bfcd609762d278bb412ce3050a89dbb78e6 /src/testing/test_merchant_instance_response.sh
parent4e0b8b34dd32e233b252a76798dca1f4823b7a4f (diff)
downloadmerchant-e51192f0e708670b19acfb3fc1c969f1702a334c.tar.gz
merchant-e51192f0e708670b19acfb3fc1c969f1702a334c.tar.bz2
merchant-e51192f0e708670b19acfb3fc1c969f1702a334c.zip
deprecate '/instances/default', for clients to just use the shorter '/' path for the default instance
Diffstat (limited to 'src/testing/test_merchant_instance_response.sh')
-rwxr-xr-xsrc/testing/test_merchant_instance_response.sh18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/testing/test_merchant_instance_response.sh b/src/testing/test_merchant_instance_response.sh
index 336c33cc..066efb67 100755
--- a/src/testing/test_merchant_instance_response.sh
+++ b/src/testing/test_merchant_instance_response.sh
@@ -24,7 +24,7 @@ setup -c test_template.conf -m
STATUS=$(curl -H "Content-Type: application/json" -X OPTIONS \
- http://localhost:9966/instances/default/private/products \
+ http://localhost:9966/private/products \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "204" ]
@@ -34,7 +34,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X GET \
-H 'Authorization: Bearer secret-token:super_secret' \
- http://localhost:9966/instances/default/private/products \
+ http://localhost:9966/private/products \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "404" ]
@@ -54,7 +54,7 @@ then
fi
STATUS=$(curl -H "Content-Type: application/json" -X GET \
- http://localhost:9966/instances/default/private/products \
+ http://localhost:9966/private/products \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "401" ]
@@ -64,7 +64,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X GET \
-H 'Authorization: Bearer secret-token:other_secret' \
- http://localhost:9966/instances/default/private/products \
+ http://localhost:9966/private/products \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "200" ]
@@ -74,7 +74,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X POST \
-H 'Authorization: Bearer secret-token:other_secret' \
- http://localhost:9966/instances/default/private/auth \
+ http://localhost:9966/private/auth \
-d '{"method":"token","token":"secret-token:zxc"}' \
-w "%{http_code}" -s -o /dev/null)
@@ -85,7 +85,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X DELETE \
- "http://localhost:9966/instances/default/private" \
+ "http://localhost:9966/private" \
-w "%{http_code}" -s -o /dev/null)
@@ -96,7 +96,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X DELETE \
-H 'Authorization: Bearer secret-token:other_secret' \
- "http://localhost:9966/instances/default/private" \
+ "http://localhost:9966/private" \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "401" ]
@@ -106,7 +106,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X DELETE \
-H 'Authorization: Bearer secret-token:zxc' \
- "http://localhost:9966/instances/default/private" \
+ "http://localhost:9966/private" \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "204" ]
@@ -116,7 +116,7 @@ fi
STATUS=$(curl -H "Content-Type: application/json" -X GET \
-H 'Authorization: Bearer secret-token:zxc' \
- http://localhost:9966/instances/default/private/products \
+ http://localhost:9966/private/products \
-w "%{http_code}" -s -o /dev/null)
if [ "$STATUS" != "404" ]