summaryrefslogtreecommitdiff
path: root/regress/bin/ksh
diff options
context:
space:
mode:
Diffstat (limited to 'regress/bin/ksh')
-rw-r--r--regress/bin/ksh/Makefile7
-rw-r--r--regress/bin/ksh/eval.sh15
2 files changed, 20 insertions, 2 deletions
diff --git a/regress/bin/ksh/Makefile b/regress/bin/ksh/Makefile
index 25e141b061a..ae966f67b2c 100644
--- a/regress/bin/ksh/Makefile
+++ b/regress/bin/ksh/Makefile
@@ -1,6 +1,6 @@
-# $OpenBSD: Makefile,v 1.4 2003/12/15 05:28:40 otto Exp $
+# $OpenBSD: Makefile,v 1.5 2010/03/24 08:29:44 fgsch Exp $
-REGRESS_TARGETS=shcrash.sh seterror.sh varfunction.sh
+REGRESS_TARGETS=shcrash.sh seterror.sh varfunction.sh eval.sh
shcrash.sh:
ulimit -c 0 && sh ${.CURDIR}/shcrash.sh
@@ -11,6 +11,9 @@ seterror.sh:
varfunction.sh:
sh ${.CURDIR}/varfunction.sh
+eval.sh:
+ test `sh ${.CURDIR}/eval.sh | wc -l` == 4
+
.PHONY: ${REGRESS_TARGETS}
.include <bsd.regress.mk>
diff --git a/regress/bin/ksh/eval.sh b/regress/bin/ksh/eval.sh
new file mode 100644
index 00000000000..fb6d01f281b
--- /dev/null
+++ b/regress/bin/ksh/eval.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+#
+# $Id: eval.sh,v 1.1 2010/03/24 08:29:44 fgsch Exp $
+
+for n in ${a#*=}; do echo ${n}; done
+for n in "${a#*=}"; do echo ${n}; done
+
+for n in ${a##*=}; do echo ${n}; done
+for n in "${a##*=}"; do echo ${n}; done
+
+for n in ${a%=*}; do echo ${n}; done
+for n in "${a%=*}"; do echo ${n}; done
+
+for n in ${a%%=*}; do echo ${n}; done
+for n in "${a%%=*}"; do echo ${n}; done