From e2e69d153f60b12ba5647f16223b77cb2deb1c5b Mon Sep 17 00:00:00 2001 From: lightvector Date: Mon, 29 Jun 2015 01:46:12 -0400 Subject: [PATCH] Add test scripts --- getjson.sh | 5 +++++ postjson.sh | 5 +++++ 2 files changed, 10 insertions(+) create mode 100755 getjson.sh create mode 100755 postjson.sh diff --git a/getjson.sh b/getjson.sh new file mode 100755 index 0000000..9fd8d26 --- /dev/null +++ b/getjson.sh @@ -0,0 +1,5 @@ +#!/bin/bash -eux +#Convenience script for sending queries to a test server +curl -i -H "Content-Type: application/json" -X GET "http://localhost:8080/$1" +{ set +x; } 2>/dev/null +echo "" diff --git a/postjson.sh b/postjson.sh new file mode 100755 index 0000000..daa776b --- /dev/null +++ b/postjson.sh @@ -0,0 +1,5 @@ +#!/bin/bash -eux +#Convenience script for sending queries to a test server +curl -i -H "Content-Type: application/json" -X POST -d "$2" "http://localhost:8080/$1" +{ set +x; } 2>/dev/null +echo ""