summaryrefslogtreecommitdiff
path: root/i/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests
diff options
context:
space:
mode:
Diffstat (limited to 'i/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests')
-rwxr-xr-xi/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests19
1 files changed, 19 insertions, 0 deletions
diff --git a/i/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests b/i/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests
new file mode 100755
index 0000000..8393d95
--- /dev/null
+++ b/i/pc104/initrd/conf/busybox/shell/ash_test/ash-invert/invert.tests
@@ -0,0 +1,19 @@
+# tests of return value inversion
+# placeholder for future expansion
+
+# user subshells (...) did this wrong in bash versions before 2.04
+
+! ( echo hello | grep h >/dev/null 2>&1 ); echo $?
+! echo hello | grep h >/dev/null 2>&1 ; echo $?
+
+! true ; echo $?
+! false; echo $?
+
+! (false) ; echo $?
+! (true); echo $?
+
+! true | false ; echo $?
+! false | true ; echo $?
+
+! (true | false) ; echo $?
+! (false | true) ; echo $?