From 64925384c9cf5e0d986e183577da286bb3207ce7 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Tue, 25 Jul 2017 14:55:05 +0200 Subject: ash: add a few tests from hush-vars/* Signed-off-by: Denys Vlasenko --- shell/hush_test/hush-vars/param_expand_bash_substring.tests | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'shell/hush_test/hush-vars/param_expand_bash_substring.tests') diff --git a/shell/hush_test/hush-vars/param_expand_bash_substring.tests b/shell/hush_test/hush-vars/param_expand_bash_substring.tests index 5c9552dba..cce9f123e 100755 --- a/shell/hush_test/hush-vars/param_expand_bash_substring.tests +++ b/shell/hush_test/hush-vars/param_expand_bash_substring.tests @@ -1,13 +1,14 @@ # first try some invalid patterns # do all of these in subshells since it's supposed to error out +# (set argv0 to "SHELL" to avoid "/path/to/shell: blah" in error messages) export var=0123456789 -"$THIS_SH" -c 'echo ${:}' -"$THIS_SH" -c 'echo ${::}' -"$THIS_SH" -c 'echo ${:1}' -"$THIS_SH" -c 'echo ${::1}' +"$THIS_SH" -c 'echo ${:}' SHELL +"$THIS_SH" -c 'echo ${::}' SHELL +"$THIS_SH" -c 'echo ${:1}' SHELL +"$THIS_SH" -c 'echo ${::1}' SHELL -#this also is not valid in bash, but we accept it: -"$THIS_SH" -c 'echo ${var:}' +#this also is not valid in bash, hush accepts it: +"$THIS_SH" -c 'echo ${var:}' SHELL # then some funky ones # UNFIXED BUG: this should work: "$THIS_SH" -c 'echo ${?:0}' -- cgit v1.2.3