test: == not portable

This commit is contained in:
Nero 2022-09-21 12:14:45 +00:00
parent c75cbff329
commit d5d466aad5

View File

@ -3,7 +3,7 @@ PROG=${1:-./sh_quote}
run_test() { run_test() {
r=$($PROG "$2"|sed 's/^ *//;s/ *$//') r=$($PROG "$2"|sed 's/^ *//;s/ *$//')
if test "$r" == "$3"; then if test "$r" = "$3"; then
echo PASS "$1" echo PASS "$1"
else else
echo FAIL "$1" echo FAIL "$1"