Do not add inspec's bin path to the PATH env var

By not adding inspec's bin path to the PATH env var
we can properly test that inspec's install scripts
created the appropriate symlinks.

Signed-off-by: Jeremiah Snapp <jeremiah@chef.io>
This commit is contained in:
Jeremiah Snapp 2019-04-15 17:00:52 -04:00
parent 8533998fb8
commit 265ce834ad

View file

@ -13,11 +13,9 @@ check-omnibus-package-signed "$package_file"
echo "--- Testing $channel $product $version"
export INSTALL_DIR=/opt/inspec
export PATH="/opt/inspec/bin:$PATH"
echo "Verifying ownership of package files"
export INSTALL_DIR=/opt/inspec
NONROOT_FILES="$(find "$INSTALL_DIR" ! -uid 0 -print)"
if [[ "$NONROOT_FILES" == "" ]]; then
echo "Packages files are owned by root. Continuing verification."
@ -34,5 +32,4 @@ echo "Running verification for $product"
export GEM_HOME=/SHOULD_NOT_EXIST
export GEM_PATH=/SHOULD_NOT_EXIST
export PATH="$PATH:/usr/local/bin"
inspec version