summaryrefslogtreecommitdiff
path: root/release/src/router/busybox/shell/hush_test/hush-trap/usage.tests
diff options
context:
space:
mode:
Diffstat (limited to 'release/src/router/busybox/shell/hush_test/hush-trap/usage.tests')
-rwxr-xr-xrelease/src/router/busybox/shell/hush_test/hush-trap/usage.tests23
1 files changed, 23 insertions, 0 deletions
diff --git a/release/src/router/busybox/shell/hush_test/hush-trap/usage.tests b/release/src/router/busybox/shell/hush_test/hush-trap/usage.tests
new file mode 100755
index 00000000..d29c6e74
--- /dev/null
+++ b/release/src/router/busybox/shell/hush_test/hush-trap/usage.tests
@@ -0,0 +1,23 @@
+# no output -- default state
+echo ___
+trap
+
+# assign some traps
+echo ___
+trap "a" EXIT INT USR1 USR2
+
+# show them all
+echo ___
+trap
+
+# clear one
+echo ___
+trap 0 INT
+echo ___
+trap
+
+# clear another
+echo ___
+trap "-" USR1
+echo ___
+trap