fork/fish-shell

git clone https://git.julia.blue/fork/fish-shell

Johannes Altmanningertests: filter control sequences only when interactive1e858eae3

master
1.1 KiB34 linesraw
1#RUN: %fish %s
2echo $foo[0]
3#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
4#CHECKERR: echo $foo[0]
5#CHECKERR: ^
6echo $foo[ 0 ]
7#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
8#CHECKERR: echo $foo[ 0 ]
9#CHECKERR: ^
10echo $foo[ 00 ]
11#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
12#CHECKERR: echo $foo[ 00 ]
13#CHECKERR: ^
14echo $foo[+0]
15#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
16#CHECKERR: echo $foo[+0]
17#CHECKERR: ^
18echo $foo[-0]
19#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
20#CHECKERR: echo $foo[-0]
21#CHECKERR: ^
22echo $foo[0..1]
23#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
24#CHECKERR: echo $foo[0..1]
25#CHECKERR:           ^
26echo $foo[1..0]
27#CHECKERR: {{.*}}checks/zero_based_array.fish (line {{\d+}}): array indices start at 1, not 0.
28#CHECKERR: echo $foo[1..0]
29#CHECKERR:              ^
30
31# and make sure these didn't break
32set -l foo one two three
33echo $foo[001]
34#CHECK: one