aboutsummaryrefslogtreecommitdiff
path: root/shell/hush_test
diff options
context:
space:
mode:
Diffstat (limited to 'shell/hush_test')
-rw-r--r--shell/hush_test/hush-quoting/squote_in_varexp1.right3
-rwxr-xr-xshell/hush_test/hush-quoting/squote_in_varexp1.tests4
-rw-r--r--shell/hush_test/hush-quoting/squote_in_varexp2.right3
-rwxr-xr-xshell/hush_test/hush-quoting/squote_in_varexp2.tests4
4 files changed, 14 insertions, 0 deletions
diff --git a/shell/hush_test/hush-quoting/squote_in_varexp1.right b/shell/hush_test/hush-quoting/squote_in_varexp1.right
new file mode 100644
index 000000000..9d0add3c5
--- /dev/null
+++ b/shell/hush_test/hush-quoting/squote_in_varexp1.right
@@ -0,0 +1,3 @@
+Nothing:
+Nothing:
+Ok:0
diff --git a/shell/hush_test/hush-quoting/squote_in_varexp1.tests b/shell/hush_test/hush-quoting/squote_in_varexp1.tests
new file mode 100755
index 000000000..efb380db3
--- /dev/null
+++ b/shell/hush_test/hush-quoting/squote_in_varexp1.tests
@@ -0,0 +1,4 @@
+x='\\\\'
+printf Nothing:'%s\n' ${x#\\\\\\\\}
+printf Nothing:'%s\n' "${x#\\\\\\\\}"
+echo Ok:$?
diff --git a/shell/hush_test/hush-quoting/squote_in_varexp2.right b/shell/hush_test/hush-quoting/squote_in_varexp2.right
new file mode 100644
index 000000000..9d0add3c5
--- /dev/null
+++ b/shell/hush_test/hush-quoting/squote_in_varexp2.right
@@ -0,0 +1,3 @@
+Nothing:
+Nothing:
+Ok:0
diff --git a/shell/hush_test/hush-quoting/squote_in_varexp2.tests b/shell/hush_test/hush-quoting/squote_in_varexp2.tests
new file mode 100755
index 000000000..806ad12b9
--- /dev/null
+++ b/shell/hush_test/hush-quoting/squote_in_varexp2.tests
@@ -0,0 +1,4 @@
+x='\\\\'
+printf Nothing:'%s\n' ${x#'\\\\'}
+printf Nothing:'%s\n' "${x#'\\\\'}"
+echo Ok:$?