summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-10-03 15:07:57 (GMT)
committer Denys Vlasenko <vda.linux@googlemail.com>2010-10-03 15:07:57 (GMT)
commit2bcba5cc53a171fba2d9d0b5185f45d8026a2657 (patch)
tree503c6d797835a2bd0dfa43ffea60de55183ff5d9
parent9e800223f13edeb02412936c810e7ee79f35c27c (diff)
downloadbusybox-2bcba5cc53a171fba2d9d0b5185f45d8026a2657.tar.gz
busybox-2bcba5cc53a171fba2d9d0b5185f45d8026a2657.tar.bz2
hush: add brace expansion testcase
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--shell/hush_test/hush-glob/bash_brace1.right4
-rwxr-xr-xshell/hush_test/hush-glob/bash_brace1.tests10
2 files changed, 14 insertions, 0 deletions
diff --git a/shell/hush_test/hush-glob/bash_brace1.right b/shell/hush_test/hush-glob/bash_brace1.right
new file mode 100644
index 0000000..63365c9
--- /dev/null
+++ b/shell/hush_test/hush-glob/bash_brace1.right
@@ -0,0 +1,4 @@
+bash_brace1.tests
+*{b,b}race1.t*
+bash_brace1.tests bash_brace1.tests
+Done: 0
diff --git a/shell/hush_test/hush-glob/bash_brace1.tests b/shell/hush_test/hush-glob/bash_brace1.tests
new file mode 100755
index 0000000..eb2f0e9
--- /dev/null
+++ b/shell/hush_test/hush-glob/bash_brace1.tests
@@ -0,0 +1,10 @@
+# unquoted $v should be globbed:
+v='*brace1.t*'; echo $v
+
+# ...but not brace expanded:
+v='*{b,b}race1.t*'; echo $v
+
+# whereas direct brces are expanded:
+echo *{b,b}race1.t*
+
+echo Done: $?