X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fscript.test.sh;h=87a2e08336aa5d40093dbf25edeabf3182e7e63b;hb=dd5c055b2ddd60e76fa9c17c2d6d97b3b5032a6e;hp=e17761a5d04a226eb63e2b5191128a8e0b9d0287;hpb=4993cd552cc06b6889a2b1898448cb2687ed0b6c;p=sbcl.git diff --git a/tests/script.test.sh b/tests/script.test.sh index e17761a..87a2e08 100644 --- a/tests/script.test.sh +++ b/tests/script.test.sh @@ -38,13 +38,31 @@ run_sbcl --script $tmpscript check_status_maybe_lose "--script exit status from normal exit" $? 0 "(everything ok)" cat > $tmpscript </dev/null +check_status_maybe_lose "--script exit status from QUIT when standard-output closed" $? 3 "(as given)" +run_sbcl --load $tmpscript >/dev/null +check_status_maybe_lose "--load exit status from QUIT when standard-output closed" $? 3 "(as given)" + +cat > $tmpscript </dev/null +check_status_maybe_lose "--script exit status from QUIT when original standard-output closed" $? 3 "(as given)" +run_sbcl --load $tmpscript >/dev/null +check_status_maybe_lose "--load exit status from QUIT when original standard-output closed" $? 3 "(as given)" + +cat > $tmpscript </dev/null check_status_maybe_lose "--script exit status from QUIT when stdout closed" $? 3 "(as given)" -run_sbcl --load $tmpscript +run_sbcl --load $tmpscript >/dev/null check_status_maybe_lose "--load exit status from QUIT when stdout closed" $? 3 "(as given)" cat > $tmpscript < $tmpscript < $tmpout +if [ "`grep -c :SCRIPT-OK $tmpout`" != 1 ] ; then + echo "failed --script test using PRINT" + exit $EXIT_LOSE +fi + rm -f $tmpscript $tmpout $tmperr exit $EXIT_TEST_WIN