Added test for config with spaces

This commit is contained in:
Ludovic Perrine
2014-10-02 12:27:12 +02:00
committed by Jose Diaz-Gonzalez
parent 5dbc864060
commit 361011ec69
3 changed files with 18 additions and 2 deletions

View File

@@ -1,3 +1,15 @@
#!/bin/bash
set -e; output="$(curl -s $1)"; echo $output; test "$output" == "config-test"
set -e;
base_url="$1"
test_url / "config-test"
test_url /hello "Hello world"
test_url () {
path="$1"
expected_output="$2"
url="$base_url$path"
output="$(curl -s $url)"
echo $output
test "$output" == "$expected_output"
}