summaryrefslogtreecommitdiff
path: root/shell/ash_test
diff options
context:
space:
mode:
authorDenis Vlasenko2008-04-12 23:02:43 +0000
committerDenis Vlasenko2008-04-12 23:02:43 +0000
commitf78a656f7c287c0963d985490b3e77751b4a81bc (patch)
tree3cb35cb2c2fb0ef761abceaefc7d3240821fa524 /shell/ash_test
parent033424a213739edb0dbe3f572bc22825b1c17d7b (diff)
downloadbusybox-f78a656f7c287c0963d985490b3e77751b4a81bc.zip
busybox-f78a656f7c287c0963d985490b3e77751b4a81bc.tar.gz
ash: a bit more complete POSIX subst testsuite entry
Diffstat (limited to 'shell/ash_test')
-rw-r--r--shell/ash_test/ash-vars/var_posix1.right7
-rwxr-xr-xshell/ash_test/ash-vars/var_posix1.tests12
2 files changed, 17 insertions, 2 deletions
diff --git a/shell/ash_test/ash-vars/var_posix1.right b/shell/ash_test/ash-vars/var_posix1.right
index 013b223..55f3579 100644
--- a/shell/ash_test/ash-vars/var_posix1.right
+++ b/shell/ash_test/ash-vars/var_posix1.right
@@ -3,8 +3,15 @@ abcdcd
abcdcd
cdcd
babcdcd
+babcdcd
+ababcdcd
+
ababcd
ababcd
ababcd
abab
ababcdc
+ababcdc
+ababcdcd
+
+end
diff --git a/shell/ash_test/ash-vars/var_posix1.tests b/shell/ash_test/ash-vars/var_posix1.tests
index a7c85cb..4139e2c 100755
--- a/shell/ash_test/ash-vars/var_posix1.tests
+++ b/shell/ash_test/ash-vars/var_posix1.tests
@@ -1,13 +1,21 @@
var=ababcdcd
echo ${var#ab}
-echo ${var#a*b}
echo ${var##ab}
+echo ${var#a*b}
echo ${var##a*b}
echo ${var#?}
+echo ${var##?}
+echo ${var#*}
+echo ${var##*}
echo ${var%cd}
-echo ${var%c*d}
echo ${var%%cd}
+echo ${var%c*d}
echo ${var%%c*d}
echo ${var%?}
+echo ${var%%?}
+echo ${var%*}
+echo ${var%%*}
+
+echo end