Don't error for stuff that should be allowed to fail (checking missing path)
This commit is contained in:
parent
eab07ba4d8
commit
9025ef5eef
11
test_cli.sh
11
test_cli.sh
|
@ -29,13 +29,18 @@ if [ -z "$1" ]; then
|
|||
# cli script needs to be executed to get absolute path to the program
|
||||
export WHCK="$("$FIND_WHCK")"
|
||||
else
|
||||
if WHCK="$(realpath -q "$ORIGDIR"/"$1")"; then
|
||||
export WHCK
|
||||
if [ -x "$ORIGDIR"/"$1" ]; then
|
||||
export WHCK="$(realpath "$ORIGDIR"/"$1")"
|
||||
elif [ -x "$1" ]; then
|
||||
export WHCK="$(realpath "$ORIGDIR"/"$1")"
|
||||
else
|
||||
export WHCK="$(realpath "$1")"
|
||||
echo "ERROR: Could not find provided validation program: "$1""
|
||||
exit 2
|
||||
fi
|
||||
fi
|
||||
|
||||
bats tests/cli/*.bats
|
||||
status=$?
|
||||
|
||||
cd "$ORIGDIR"
|
||||
exit $status
|
||||
|
|
Loading…
Reference in New Issue