diff --git a/tests/lean/test.sh b/tests/lean/test.sh index 0a54f2f9d8..35dfca742e 100755 --- a/tests/lean/test.sh +++ b/tests/lean/test.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash +cd "$(dirname "$0")" if [ $# -ne 2 -a $# -ne 1 ]; then echo "Usage: test.sh [lean-executable-path] [yes/no]?" exit 1 @@ -12,7 +13,7 @@ else INTERACTIVE=$2 fi NUM_ERRORS=0 -for f in `ls *.lean`; do +for f in *.lean; do echo "-- testing $f" $LEAN -t config.lean $f &> $f.produced.out if test -f $f.expected.out; then diff --git a/tests/lua/test.sh b/tests/lua/test.sh index 473c636419..9bdcf1e5ba 100755 --- a/tests/lua/test.sh +++ b/tests/lua/test.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash +cd "$(dirname "$0")" if [ $# -ne 1 ]; then echo "Usage: test.sh [lean-executable-path]" exit 1 @@ -6,7 +7,7 @@ fi ulimit -s unlimited LEAN=$1 NUM_ERRORS=0 -for f in `ls *.lua`; do +for f in *.lua; do echo "-- testing $f" if $LEAN extra.lua $f > $f.produced.out; then echo "-- worked"