2020-01-24 01:34:46 +00:00
|
|
|
# RUN: %fish %s
|
|
|
|
|
|
|
|
# Empty commands should be 123
|
|
|
|
set empty_var
|
|
|
|
$empty_var
|
|
|
|
echo $status
|
|
|
|
# CHECK: 123
|
|
|
|
# CHECKERR: {{.*}} The expanded command was empty.
|
|
|
|
# CHECKERR: $empty_var
|
2022-08-11 16:20:40 +00:00
|
|
|
# CHECKERR: ^~~~~~~~~^
|
2020-01-24 01:34:46 +00:00
|
|
|
|
|
|
|
# Failed expansions
|
|
|
|
echo "$abc["
|
|
|
|
echo $status
|
|
|
|
# CHECK: 121
|
|
|
|
# CHECKERR: {{.*}} Invalid index value
|
|
|
|
# CHECKERR: echo "$abc["
|
2022-08-11 17:24:41 +00:00
|
|
|
# CHECKERR: ^
|
2020-01-24 01:34:46 +00:00
|
|
|
|
|
|
|
# Failed wildcards
|
|
|
|
echo *gibberishgibberishgibberish*
|
|
|
|
echo $status
|
|
|
|
# CHECK: 124
|
|
|
|
# CHECKERR: {{.*}} No matches for wildcard '*gibberishgibberishgibberish*'. {{.*}}
|
|
|
|
# CHECKERR: echo *gibberishgibberishgibberish*
|
2022-08-11 15:22:03 +00:00
|
|
|
# CHECKERR: ^~~~~~~~~~~~~~~~~~~~~~~~~~~~^
|