diff options
Diffstat (limited to 'src/namestore/test_plugin_rest_namestore.sh')
-rwxr-xr-x | src/namestore/test_plugin_rest_namestore.sh | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/namestore/test_plugin_rest_namestore.sh b/src/namestore/test_plugin_rest_namestore.sh index 8a45cebf5..50b3c8c12 100755 --- a/src/namestore/test_plugin_rest_namestore.sh +++ b/src/namestore/test_plugin_rest_namestore.sh | |||
@@ -78,15 +78,16 @@ curl_delete () { | |||
78 | 78 | ||
79 | TEST_ID="test" | 79 | TEST_ID="test" |
80 | gnunet-arm -s -c test_namestore_api.conf | 80 | gnunet-arm -s -c test_namestore_api.conf |
81 | gnunet-arm -i rest -c test_namestore_api.conf | ||
82 | #Test GET | 81 | #Test GET |
83 | gnunet-identity -C $TEST_ID -c test_namestore_api.conf | 82 | gnunet-identity -C $TEST_ID -c test_namestore_api.conf |
84 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" | 83 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" |
85 | name=$TEST_ID | 84 | name=$TEST_ID |
86 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" | 85 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" |
87 | echo "$name $public" | 86 | echo "$name $public" |
88 | valgrind gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | 87 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
89 | #curl_get "${namestore_link}" "HTTP/1.1 200 OK" | 88 | sleep 1 |
89 | gnunet-arm -i rest -c test_namestore_api.conf | ||
90 | sleep 1 | ||
90 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" | 91 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" |
91 | curl_get "${namestore_link}/$public" "error" | 92 | curl_get "${namestore_link}/$public" "error" |
92 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf | 93 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf |
@@ -128,9 +129,6 @@ gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/ | |||
128 | #Test DELETE | 129 | #Test DELETE |
129 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | 130 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
130 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" | 131 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" |
131 | curl_delete "${namestore_link}/$name/test_entry" "error" | ||
132 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | ||
133 | curl_delete "${namestore_link}/$public/test_entry" "error" | ||
134 | 132 | ||
135 | gnunet-arm -e -c test_namestore_api.conf | 133 | gnunet-arm -e -c test_namestore_api.conf |
136 | exit 0; | 134 | exit 0; |