diff options
-rw-r--r-- | .expeditor/verify.pipeline.yml | 7 | ||||
-rwxr-xr-x | habitat/tests/test.sh | 6 | ||||
-rwxr-xr-x | scripts/ci/install-hab.sh | 1 | ||||
-rwxr-xr-x | scripts/ci/verify-plan.sh | 1 |
4 files changed, 6 insertions, 9 deletions
diff --git a/.expeditor/verify.pipeline.yml b/.expeditor/verify.pipeline.yml index c64a203c40..34a2dee47d 100644 --- a/.expeditor/verify.pipeline.yml +++ b/.expeditor/verify.pipeline.yml @@ -590,9 +590,6 @@ steps: linux: privileged: true single-use: true - environment: - - HAB_NONINTERACTIVE=true - - label: ":habicat: Linux plan (kernel2)" commands: @@ -604,8 +601,6 @@ steps: linux: privileged: true single-use: true - environment: - - HAB_NONINTERACTIVE=true - label: ":habicat: Windows plan" commands: @@ -616,5 +611,3 @@ steps: privileged: true single-use: true shell: ["powershell", "-Command"] - environment: - - HAB_NONINTERACTIVE=true diff --git a/habitat/tests/test.sh b/habitat/tests/test.sh index 0882313c8e..2fcd7dafd5 100755 --- a/habitat/tests/test.sh +++ b/habitat/tests/test.sh @@ -4,6 +4,7 @@ set -euo pipefail export CHEF_LICENSE="accept-no-persist" export HAB_LICENSE="accept-no-persist" +export HAB_NONINTERACTIVE="true" project_root="$(git rev-parse --show-toplevel)" pkg_ident="$1" @@ -24,11 +25,12 @@ package_version=$(awk -F / '{print $3}' <<<"$pkg_ident") cd "${project_root}" echo "--- :mag_right: Testing ${pkg_ident} executables" -[[ "$package_version" = "$(hab pkg exec "${pkg_ident}" chef-client --version | sed 's/.*: //')" ]] || error "chef-client is not the expected version" +actual_version=$(hab pkg exec "${pkg_ident}" chef-client -- --version | sed 's/.*: //') +[[ "$package_version" = "$actual_version" ]] || error "chef-client is not the expected version. Expected '$package_version', got '$actual_version'" for executable in 'chef-client' 'ohai' 'chef-shell' 'chef-apply' 'knife' 'chef-solo'; do echo -en "\t$executable = " - hab pkg exec "${pkg_ident}" "${executable}" --version || error "${executable} failed to execute properly" + hab pkg exec "${pkg_ident}" "${executable}" -- --version || error "${executable} failed to execute properly" done echo "--- :mag_right: Testing ${pkg_ident} functionality" diff --git a/scripts/ci/install-hab.sh b/scripts/ci/install-hab.sh index b65a89d706..75e910bfab 100755 --- a/scripts/ci/install-hab.sh +++ b/scripts/ci/install-hab.sh @@ -3,6 +3,7 @@ set -euo pipefail export HAB_LICENSE="accept" +export HAB_NONINTERACTIVE="true" hab_target="$1" diff --git a/scripts/ci/verify-plan.sh b/scripts/ci/verify-plan.sh index 71aac8d767..b207334267 100755 --- a/scripts/ci/verify-plan.sh +++ b/scripts/ci/verify-plan.sh @@ -6,6 +6,7 @@ export HAB_ORIGIN='ci' export PLAN='chef-infra-client' export CHEF_LICENSE="accept-no-persist" export HAB_LICENSE="accept-no-persist" +export HAB_NONINTERACTIVE="true" # print error message followed by usage and exit error () { |