aboutsummaryrefslogtreecommitdiff
path: root/src/identity/test_plugin_rest_identity.sh
diff options
context:
space:
mode:
authorPhil <phil.buschmann@tum.de>2018-08-11 14:21:58 +0200
committerPhil <phil.buschmann@tum.de>2018-08-11 14:21:58 +0200
commit4898de50936164f8adb067c4f32fab62bec92e19 (patch)
tree62b707d372685f2ebc8b56026caaa4f5238aa294 /src/identity/test_plugin_rest_identity.sh
parentbcda92da22a3c1824f966d4593492e8a446fd070 (diff)
downloadgnunet-4898de50936164f8adb067c4f32fab62bec92e19.tar.gz
gnunet-4898de50936164f8adb067c4f32fab62bec92e19.zip
split namespace of put request in identity rest api
Diffstat (limited to 'src/identity/test_plugin_rest_identity.sh')
-rwxr-xr-xsrc/identity/test_plugin_rest_identity.sh15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/identity/test_plugin_rest_identity.sh b/src/identity/test_plugin_rest_identity.sh
index 3eac0950c..a5879dd7e 100755
--- a/src/identity/test_plugin_rest_identity.sh
+++ b/src/identity/test_plugin_rest_identity.sh
@@ -122,19 +122,18 @@ curl_put "${identity_link}/name/test_plugin_rest_identity1" '{"newname":"test_pl
122curl_put "${identity_link}/name/test_plugin_rest_identity" '{"newnam":"test_plugin_rest_identityfail"}' "error" 122curl_put "${identity_link}/name/test_plugin_rest_identity" '{"newnam":"test_plugin_rest_identityfail"}' "error"
123 123
124#Test subsystem 124#Test subsystem
125curl_put "${identity_link}/name/test_plugin_rest_identity" '{"subsystem":"namestore"}' "HTTP/1.1 204" 125curl_put "${identity_link}/subsystem/test_plugin_rest_identity" '{"subsystem":"namestore"}' "HTTP/1.1 204"
126curl_put "${identity_link}/name/test_plugin_rest_identity" '{"subsystem":"namestore"}' "HTTP/1.1 204" 126curl_put "${identity_link}/subsystem/test_plugin_rest_identity" '{"subsystem":"namestore"}' "HTTP/1.1 204"
127curl_get "${identity_link}/subsystem/namestore" "test_plugin_rest_identity" 127curl_get "${identity_link}/subsystem/namestore" "test_plugin_rest_identity"
128curl_post "${identity_link}" '{"name":"test_plugin_rest_identity1"}' "HTTP/1.1 201 Created"
129public="$(gnunet-identity -d | grep "test_plugin_rest_identity" | awk 'NR==1{print $3}')" 128public="$(gnunet-identity -d | grep "test_plugin_rest_identity" | awk 'NR==1{print $3}')"
130curl_put "${identity_link}/pubkey/$public" '{"subsystem":"namestore"}' "HTTP/1.1 204" 129curl_put "${identity_link}/subsystem/$public" '{"subsystem":"namestore"}' "HTTP/1.1 404"
131curl_get "${identity_link}/subsystem/namestore" "test_plugin_rest_identity1" 130curl_post "${identity_link}" '{"name":"test_plugin_rest_identity1"}' "HTTP/1.1 201 Created"
132curl_get "${identity_link}/subsystem/test_plugin_rest_identity_no_subsystem" "error" 131curl_get "${identity_link}/subsystem/test_plugin_rest_identity_no_subsystem" "error"
133curl_put "${identity_link}/name/test_plugin_rest_identity1" '{"subsystem":"test_plugin_rest_identity_no_subsystem"}' "HTTP/1.1 204" 132curl_put "${identity_link}/subsystem/test_plugin_rest_identity1" '{"subsystem":"test_plugin_rest_identity_no_subsystem"}' "HTTP/1.1 204"
134curl_get "${identity_link}/subsystem/test_plugin_rest_identity_no_subsystem" "test_plugin_rest_identity1" 133curl_get "${identity_link}/subsystem/test_plugin_rest_identity_no_subsystem" "test_plugin_rest_identity1"
135 134
136curl_put "${identity_link}/name/test_plugin_rest_identity1" '{"subsyste":"test_plugin_rest_identity_no_subsystem"}' "error" 135curl_put "${identity_link}/subsystem/test_plugin_rest_identity1" '{"subsyste":"test_plugin_rest_identity_no_subsystem"}' "error"
137curl_put "${identity_link}/name/test_plugin_rest_identity1" '{"subsystem":"test_plugin_rest_identity_no_subsystem"}' "HTTP/1.1 204" 136curl_put "${identity_link}/subsystem/test_plugin_rest_identity1" '{"subsystem":"test_plugin_rest_identity_no_subsystem"}' "HTTP/1.1 204"
138 137
139#Test DELETE 138#Test DELETE
140curl_delete "${identity_link}/name/test_plugin_rest_identity" "HTTP/1.1 204" 139curl_delete "${identity_link}/name/test_plugin_rest_identity" "HTTP/1.1 204"