Issue #226 Fix tests
diff --git a/tests/tests.bats b/tests/tests.bats
index edd2130..bc42afc 100644
--- a/tests/tests.bats
+++ b/tests/tests.bats
@@ -16,7 +16,7 @@
@test "test multiple JENKINS_OPTS" {
# running --help --version should return the version, not the help
- local version=$(grep 'ENV JENKINS_VERSION' Dockerfile | sed -e 's/ENV JENKINS_VERSION //')
+ local version=$(grep 'ENV JENKINS_VERSION' Dockerfile | sed -e 's/.*:-\(.*\)}/\1/')
# need the last line of output, removing the last char
local actual_version=$(docker run --rm -ti -e JENKINS_OPTS="--help --version" --name $SUT_CONTAINER -P $SUT_IMAGE | tail -n 1)
assert "${version}" echo "${actual_version::-1}"
@@ -24,7 +24,7 @@
@test "test jenkins arguments" {
# running --help --version should return the version, not the help
- local version=$(grep 'ENV JENKINS_VERSION' Dockerfile | sed -e 's/ENV JENKINS_VERSION //')
+ local version=$(grep 'ENV JENKINS_VERSION' Dockerfile | sed -e 's/.*:-\(.*\)}/\1/')
# need the last line of output, removing the last char
local actual_version=$(docker run --rm -ti --name $SUT_CONTAINER -P $SUT_IMAGE --help --version | tail -n 1)
assert "${version}" echo "${actual_version::-1}"