these can't be nested and are expected to fail, although our error message
is different from bash's that's okay
This commit is contained in:
parent
a29f4f60f8
commit
cd80bc8012
6
check.t
6
check.t
|
@ -1,4 +1,4 @@
|
||||||
# $MirOS: src/bin/mksh/check.t,v 1.124 2007/07/06 02:22:55 tg Exp $
|
# $MirOS: src/bin/mksh/check.t,v 1.125 2007/07/06 11:54:34 tg Exp $
|
||||||
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
|
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
|
||||||
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
|
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
|
||||||
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
|
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
|
||||||
|
@ -4080,7 +4080,7 @@ expected-stdout:
|
||||||
name: varexpand-substr-3
|
name: varexpand-substr-3
|
||||||
description:
|
description:
|
||||||
Check that some things that work in bash fail.
|
Check that some things that work in bash fail.
|
||||||
This is by design.
|
This is by design. And that some things fail in both.
|
||||||
stdin:
|
stdin:
|
||||||
export x=abcdefghi n=2
|
export x=abcdefghi n=2
|
||||||
"$0" -c 'print v${x:(n)}x'
|
"$0" -c 'print v${x:(n)}x'
|
||||||
|
@ -4088,10 +4088,12 @@ stdin:
|
||||||
"$0" -c 'print x${x:n}x'
|
"$0" -c 'print x${x:n}x'
|
||||||
"$0" -c 'print y${x:}x'
|
"$0" -c 'print y${x:}x'
|
||||||
"$0" -c 'print z${x}x'
|
"$0" -c 'print z${x}x'
|
||||||
|
"$0" -c 'x=abcdef;y=123;echo ${x:${y:2:1}:2}' >/dev/null 2>&1; print $?
|
||||||
expected-stdout:
|
expected-stdout:
|
||||||
vcdefghix
|
vcdefghix
|
||||||
wcdefghix
|
wcdefghix
|
||||||
zabcdefghix
|
zabcdefghix
|
||||||
|
1
|
||||||
expected-stderr-pattern:
|
expected-stderr-pattern:
|
||||||
/x:n.*bad substitution.*\n.*bad substitution/
|
/x:n.*bad substitution.*\n.*bad substitution/
|
||||||
---
|
---
|
||||||
|
|
Loading…
Reference in New Issue