sh: Add forgotton test for set.
authorPeter Avalos <pavalos@dragonflybsd.org>
Sun, 25 Dec 2011 17:50:07 +0000 (09:50 -0800)
committerPeter Avalos <pavalos@dragonflybsd.org>
Sun, 25 Dec 2011 17:50:07 +0000 (09:50 -0800)
Obtained-from:  FreeBSD 222813

tools/regression/bin/sh/builtins/set1.0 [new file with mode: 0644]

diff --git a/tools/regression/bin/sh/builtins/set1.0 b/tools/regression/bin/sh/builtins/set1.0
new file mode 100644 (file)
index 0000000..2b3b55b
--- /dev/null
@@ -0,0 +1,32 @@
+# $FreeBSD: src/tools/regression/bin/sh/builtins/set1.0,v 1.2 2011/06/07 08:46:13 attilio Exp $
+
+set +C
+set +f
+set -e
+
+settings=$(set +o)
+set -C
+set -f
+set +e
+case $- in
+*C*) ;;
+*) echo missing C ;;
+esac
+case $- in
+*f*) ;;
+*) echo missing C ;;
+esac
+case $- in
+*e*) echo bad e ;;
+esac
+eval "$settings"
+case $- in
+*C*) echo bad C ;;
+esac
+case $- in
+*f*) echo bad f ;;
+esac
+case $- in
+*e*) ;;
+*) echo missing e ;;
+esac