diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2013-06-09 13:27:28 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2013-06-09 13:27:28 +0000 |
commit | 99c4222284f1497446f6d1bcaab51dc4b2f5cad3 (patch) | |
tree | 6eaad5414e002e0d1dd8e205dae55b6008d9c7ab /regress/bin | |
parent | b7b82d7589e142aa40159ef8164032b3936c526e (diff) |
Add test for "true && true && false" and "set -e".
Diffstat (limited to 'regress/bin')
-rw-r--r-- | regress/bin/ksh/Makefile | 10 | ||||
-rw-r--r-- | regress/bin/ksh/eval4.sh | 6 |
2 files changed, 14 insertions, 2 deletions
diff --git a/regress/bin/ksh/Makefile b/regress/bin/ksh/Makefile index 24ef667611f..58414361a14 100644 --- a/regress/bin/ksh/Makefile +++ b/regress/bin/ksh/Makefile @@ -1,6 +1,6 @@ -# $OpenBSD: Makefile,v 1.6 2013/06/07 08:48:18 espie Exp $ +# $OpenBSD: Makefile,v 1.7 2013/06/09 13:27:27 millert Exp $ -REGRESS_TARGETS=shcrash.sh seterror.sh varfunction.sh eval.sh eval2.sh eval3.sh +REGRESS_TARGETS=shcrash.sh seterror.sh varfunction.sh eval.sh eval2.sh eval3.sh eval4.sh shcrash.sh: ulimit -c 0 && sh ${.CURDIR}/shcrash.sh @@ -26,6 +26,12 @@ eval3.sh: # and it should return an error if ! sh ${.CURDIR}/eval3.sh >/dev/null; then true; else false; fi +eval4.sh: + # this should not print + test `sh ${.CURDIR}/eval4.sh|wc -c` == 0 + # and it should return an error + if ! sh ${.CURDIR}/eval4.sh >/dev/null; then true; else false; fi + .PHONY: ${REGRESS_TARGETS} .include <bsd.regress.mk> diff --git a/regress/bin/ksh/eval4.sh b/regress/bin/ksh/eval4.sh new file mode 100644 index 00000000000..4299193a641 --- /dev/null +++ b/regress/bin/ksh/eval4.sh @@ -0,0 +1,6 @@ +#!/bin/sh +# $OpenBSD: eval4.sh,v 1.1 2013/06/09 13:27:27 millert Exp $ + +set -e +true && true && false +echo "should not print" |