Change debconf text to claim that the default /bin/sh is dash instead of bash. close...
[posh.git] / tests / expand.t
blobd1c22af1457d6dfe4800da06f2f69e733b02bcec
1 name: expand-1
2 description:
3         Check for overzealous tilde expansion
4 category: debian,posix
5 stdin:
6         echo f~
7         echo f=~
8         echo f==~
9 expected-stdout:
10         f~
11         f=~
12         f==~
13 ---
14 name: expand-2
15 description:
16         Check trimming
17 stdin:
18         x=fooXbarXblah
19         echo 1 ${x%X*}
20         echo 2 ${x%%X*}
21         echo 3 ${x#*X}
22         echo 4 ${x##*X}
23 expected-stdout: 
24         1 fooXbar
25         2 foo
26         3 barXblah
27         4 blah
28 ---
29 name: expand-3
30 category: pdksh
31 description:
32         Check ${foo:%bar} is not allowed (ksh88 allows it...)
33 stdin:
34         x=fooXbarXblah
35         echo 1 ${x%X*}
36         echo 2 ${x:%X*}
37         echo 3 ${x:%%X*}
38         echo 4 ${x:#*X}
39         echo 5 ${x:##*X}
40 expected-exit: e = 1
41 expected-stdout: 
42         1 fooXbar
43 expected-stderr-pattern: /.*bad substitution.*/
44 ---