Results for alias.test.sh

statusbashdashashzshmkshkshtoyshsushbrushosh
pass 4742433942413322143
ok 0205500005
N-I 0101000000
BUG 1303100000
FAIL 0050074516270
total48484848484848484848
casebashdashashzshmkshkshtoyshsushbrushoshdescription
0pass BUG FAIL pass pass pass FAIL FAIL pass pass Usage of builtins
detailsdetailsdetailsdetails
1pass pass pass pass pass pass FAIL pass FAIL pass Basic alias
detailsdetails
2pass pass pass pass pass pass FAIL pass FAIL pass define and use alias on a single line
detailsdetails
3pass pass pass pass pass pass FAIL pass pass pass alias can override builtin
details
4pass pass pass pass pass pass FAIL FAIL FAIL pass defining multiple aliases, then unalias
detailsdetailsdetails
5pass pass pass pass ok FAIL FAIL FAIL pass pass alias not defined
detailsdetailsdetailsdetails
6pass pass pass pass pass pass FAIL FAIL pass pass unalias not defined
detailsdetails
7pass pass pass pass pass pass FAIL pass pass pass unalias -a
details
8pass ok FAIL ok ok FAIL FAIL FAIL pass pass List aliases by providing names
detailsdetailsdetailsdetailsdetailsdetailsdetails
9pass ok FAIL ok ok FAIL FAIL FAIL pass pass alias without args lists all aliases
detailsdetailsdetailsdetailsdetailsdetailsdetails
10pass BUG FAIL BUG BUG FAIL FAIL FAIL FAIL pass unalias without args is a usage error
detailsdetailsdetailsdetailsdetailsdetailsdetailsdetails
11pass pass pass pass pass pass FAIL pass FAIL pass alias with trailing space causes alias expansion on second word
detailsdetails
12pass pass pass pass pass pass FAIL pass FAIL pass Recursive alias expansion of first word
detailsdetails
13pass pass pass pass pass pass FAIL pass FAIL pass Recursive alias expansion of SECOND word
detailsdetails
14pass pass pass pass pass pass FAIL pass FAIL pass Expansion of alias with variable
detailsdetails
15pass pass pass pass pass pass FAIL pass FAIL pass Alias must be an unquoted word, no expansions allowed
detailsdetails
16pass pass pass pass pass pass FAIL pass FAIL pass first and second word are the same alias, but no trailing space
detailsdetails
17pass pass pass pass pass pass FAIL pass FAIL pass first and second word are the same alias, with trailing space
detailsdetails
18pass pass pass pass pass pass pass pass FAIL pass Invalid syntax of alias
details
19pass pass pass pass pass pass FAIL pass pass pass Dynamic alias definition
details
20pass pass pass pass pass FAIL FAIL pass pass pass Alias name with punctuation
detailsdetails
21pass pass pass ok ok FAIL FAIL FAIL FAIL pass Syntax error after expansion
detailsdetailsdetailsdetailsdetailsdetails
22pass pass pass pass pass pass FAIL FAIL FAIL pass Loop split across alias and arg works
detailsdetailsdetails
23pass pass pass pass pass pass FAIL FAIL FAIL ok Loop split across alias in another way
detailsdetailsdetailsdetails
24pass pass pass BUG pass pass FAIL FAIL FAIL ok Loop split across both iterative and recursive aliases
detailsdetailsdetailsdetailsdetails
25pass pass pass ok ok FAIL FAIL FAIL FAIL pass Alias with a quote in the middle is a syntax error
detailsdetailsdetailsdetailsdetailsdetails
26pass pass pass pass pass pass FAIL pass FAIL pass Alias with internal newlines
detailsdetails
27pass pass pass ok pass pass FAIL pass FAIL pass Alias trailing newline
detailsdetailsdetails
28pass pass pass pass pass pass FAIL pass FAIL pass Two aliases in pipeline
detailsdetails
29pass pass pass pass pass pass pass pass pass pass Alias not respected inside $()
30pass pass pass pass pass pass FAIL pass FAIL pass Alias can be defined and used on a single line
detailsdetails
31pass pass pass BUG pass pass FAIL FAIL pass pass Alias is respected inside eval
detailsdetailsdetails
32pass pass pass pass pass pass FAIL pass pass pass alias with redirects works
details
33pass pass pass pass pass pass FAIL pass pass pass alias with environment bindings works
details
34pass pass pass pass pass pass FAIL pass FAIL pass alias with line continuation in the middle
detailsdetails
35pass pass pass pass pass pass FAIL FAIL FAIL ok alias for left brace
detailsdetailsdetailsdetails
36pass pass pass pass pass pass FAIL FAIL FAIL ok alias for left paren
detailsdetailsdetailsdetails
37pass pass pass pass pass pass FAIL pass pass pass alias used in subshell and command sub
details
38pass pass pass pass pass pass FAIL pass pass pass alias used in here doc
details
39BUG pass pass pass pass pass FAIL FAIL FAIL pass here doc inside alias
detailsdetailsdetailsdetails
40pass N-I FAIL N-I pass pass FAIL pass pass pass Corner case: alias inside LHS array arithmetic expression
detailsdetailsdetailsdetails
41pass pass pass pass pass pass FAIL pass FAIL pass Alias that is pipeline
detailsdetails
42pass pass pass pass pass pass FAIL pass FAIL pass Alias that is && || ;
detailsdetails
43pass pass pass pass pass pass FAIL pass pass pass Alias and command sub (bug regression)
details
44pass pass pass pass pass pass FAIL pass pass pass Alias and arithmetic
details
45pass BUG pass pass pass pass FAIL pass pass pass Alias and PS4
detailsdetails
46pass pass pass pass pass pass pass pass pass ok alias with keywords
details
47pass pass pass pass pass pass FAIL pass pass pass alias with word of multiple lines
details
353 passed, 17 OK, 2 not implemented, 8 BUG, 100 failed, 0 timeouts, 0 cases skipped

Details on runs that didn't PASS

dash0 Usage of builtins

stdout:
status=1
x
stderr:
dash: 1: shopt: not found
alias: -- not found
dash: 6: foo: not found
ash0 Usage of builtins

[ash stdout] Expected 'status=0\nx\n', got 'status=1\nx\n'

stdout:
status=1
x
stderr:
ash: shopt: not found
alias: -- not found
ash: foo: not found
toysh0 Usage of builtins

[toysh stdout] Expected 'status=0\nx\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: foo: No such file or directory
sh: unalias: No such file or directory
sh: foo: No such file or directory
sush0 Usage of builtins

[sush stdout] Expected 'status=0\nx\n', got 'status=0\n'

stdout:
status=0
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: foo: command not found
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: foo: command not found
toysh1 Basic alias

[toysh stdout] Expected 'hello world\nhi\nexpected failure\n', got 'should not run this\nhi\nexpected failure\n'

stdout:
should not run this
hi
expected failure
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: hi: No such file or directory
sh: hi: No such file or directory
brush1 Basic alias

[brush stdout] Expected 'hello world\nhi\nexpected failure\n', got 'hello world\nhi\nhello world\n'

stdout:
hello world
hi
hello world
stderr:
toysh2 define and use alias on a single line

[toysh stdout] Expected 'two\nthree\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e: No such file or directory
sh: e: No such file or directory
sh: e: No such file or directory
brush2 define and use alias on a single line

[brush stdout] Expected 'two\nthree\n', got 'one\ntwo\nthree\n'

stdout:
one
two
three
stderr:
toysh3 alias can override builtin

[toysh stdout] Expected 'foo bar\n', got 'bar\n'

stdout:
bar
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
toysh4 defining multiple aliases, then unalias

[toysh stdout] Expected 'status=0\nx X\ny Y\nstatus=0\nundefined\nundefined\n' Got 'status=127\nstatus=127\nundefined\nundefined\n'

stdout:
status=127
status=127
undefined
undefined
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo-x: No such file or directory
sh: echo-y: No such file or directory
sh: unalias: No such file or directory
sh: echo-x: No such file or directory
sh: echo-y: No such file or directory
sush4 defining multiple aliases, then unalias

[sush stdout] Expected 'status=0\nx X\ny Y\nstatus=0\nundefined\nundefined\n' Got 'status=0\nstatus=0\nundefined\nundefined\n'

stdout:
status=0
status=0
undefined
undefined
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: echo-x: command not found
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 7: echo-y: command not found
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 10: echo-x: command not found
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 11: echo-y: command not found
brush4 defining multiple aliases, then unalias

[brush stdout] Expected 'status=0\nx X\ny Y\nstatus=0\nundefined\nundefined\n' Got 'status=0\n$x X\n$y Y\nstatus=0\nundefined\nundefined\n'

stdout:
status=0
$x X
$y Y
status=0
undefined
undefined
stderr:
echo-x: command not found
echo-y: command not found
mksh5 alias not defined

stdout:
nonexistentZ alias not found
status=1
stderr:
ksh5 alias not defined

[ksh stdout] Expected 'status=1\n', got 'nonexistentZ alias not found\nstatus=1\n'

stdout:
nonexistentZ alias not found
status=1
stderr:
toysh5 alias not defined

[toysh stdout] Expected 'status=1\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: alias: No such file or directory
sush5 alias not defined

[sush stdout] Expected 'status=1\n', got 'status=0\n'

stdout:
status=0
stderr:
toysh6 unalias not defined

[toysh stdout] Expected 'status=1\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: alias: No such file or directory
sh: unalias: No such file or directory
sush6 unalias not defined

[sush stdout] Expected 'status=1\n', got 'status=0\n'

stdout:
status=0
stderr:
toysh7 unalias -a

[toysh stdout] Expected '2\nstatus=0\n', got '0\nstatus=127\n'

stdout:
0
status=127
stderr:
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: unalias: No such file or directory
sh: alias: No such file or directory
dash8 List aliases by providing names

stdout:
e='echo'
ll='ls -l'
stderr:
ash8 List aliases by providing names

[ash stdout] Expected "alias e='echo'\nalias ll='ls -l'\n", got "e='echo'\nll='ls -l'\n"

stdout:
e='echo'
ll='ls -l'
stderr:
zsh8 List aliases by providing names

stdout:
e=echo
ll='ls -l'
stderr:
mksh8 List aliases by providing names

stdout:
e=echo
ll='ls -l'
stderr:
ksh8 List aliases by providing names

[ksh stdout] Expected "alias e='echo'\nalias ll='ls -l'\n", got "e=echo\nll='ls -l'\n"

stdout:
e=echo
ll='ls -l'
stderr:
toysh8 List aliases by providing names

[toysh stdout] Expected "alias e='echo'\nalias ll='ls -l'\n", got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: alias: No such file or directory
sh: alias: No such file or directory
sush8 List aliases by providing names

[sush stdout] Expected "alias e='echo'\nalias ll='ls -l'\n", got ''

stdout:
stderr: 
dash9 alias without args lists all aliases

stdout:
ex='exit'
ll='ls -l'
status=0
stderr:
ash9 alias without args lists all aliases

[ash stdout] Expected "alias ex='exit'\nalias ll='ls -l'\nstatus=0\n" Got "ex='exit'\nll='ls -l'\nstatus=0\n"

stdout:
ex='exit'
ll='ls -l'
status=0
stderr:
zsh9 alias without args lists all aliases

stdout:
ex=exit
ll='ls -l'
status=0
stderr:
mksh9 alias without args lists all aliases

stdout:
ex=exit
ll='ls -l'
status=0
stderr:
ksh9 alias without args lists all aliases

[ksh stdout] Expected "alias ex='exit'\nalias ll='ls -l'\nstatus=0\n" Got "ex=exit\nll='ls -l'\nstatus=0\n"

stdout:
ex=exit
ll='ls -l'
status=0
stderr:
toysh9 alias without args lists all aliases

[toysh stdout] Expected "alias ex='exit'\nalias ll='ls -l'\nstatus=0\n" Got 'status=1\n'

stdout:
status=1
stderr:
sh: alias: No such file or directory
sh: alias: No such file or directory
sush9 alias without args lists all aliases

[sush stdout] Expected "alias ex='exit'\nalias ll='ls -l'\nstatus=0\n" Got 'status=1\n'

stdout:
status=1
stderr:
dash10 unalias without args is a usage error

stdout:
status=0
stderr:
ash10 unalias without args is a usage error

[ash stdout] Expected 'status=2\n', got 'status=0\n'

stdout:
status=0
stderr:
zsh10 unalias without args is a usage error

stdout:
status=1
stderr:
unalias: not enough arguments
mksh10 unalias without args is a usage error

stdout:
status=0
stderr:
ksh10 unalias without args is a usage error

[ksh stdout] Expected 'status=2\n', got 'status=0\n'

stdout:
status=0
stderr:
toysh10 unalias without args is a usage error

[toysh stdout] Expected 'status=2\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: unalias: No such file or directory
sush10 unalias without args is a usage error

[sush stdout] Expected 'status=2\n', got 'unalias: usage: unalias [-a] name [name ...]\nstatus=0\n'

stdout:
unalias: usage: unalias [-a] name [name ...]
status=0
stderr:
brush10 unalias without args is a usage error

[brush stdout] Expected 'status=2\n', got 'status=0\n'

stdout:
status=0
stderr:
toysh11 alias with trailing space causes alias expansion on second word

[toysh stdout] Expected 'hello world !!!\nhello world punct\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: hi: No such file or directory
sh: alias: No such file or directory
sh: hi: No such file or directory
brush11 alias with trailing space causes alias expansion on second word

[brush stdout] Expected 'hello world !!!\nhello world punct\n', got 'hello world punct\nhello world punct\n'

stdout:
hello world punct
hello world punct
stderr:
toysh12 Recursive alias expansion of first word

[toysh stdout] Expected '__ hello world\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: hi: No such file or directory
brush12 Recursive alias expansion of first word

[brush stdout] Expected '__ hello world\n', got ''
[brush status] Expected 0, got 127

stdout:
stderr: 
e_: command not found
toysh13 Recursive alias expansion of SECOND word

[toysh stdout] Expected 'one TWO hello world\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
brush13 Recursive alias expansion of SECOND word

[brush stdout] Expected 'one TWO hello world\n', got 'one two hello world\n'

stdout:
one two hello world
stderr:
toysh14 Expansion of alias with variable

[toysh stdout] Expected 'y hi\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo-x: No such file or directory
brush14 Expansion of alias with variable

[brush stdout] Expected 'y hi\n', got '$x hi\n'

stdout:
$x hi
stderr:
toysh15 Alias must be an unquoted word, no expansions allowed

[toysh stdout] Expected 'X\nstatus=127\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo_alias_: No such file or directory
sh: echo_alias_: No such file or directory
brush15 Alias must be an unquoted word, no expansions allowed

[brush stdout] Expected 'X\nstatus=127\n', got 'X\nX\nstatus=0\n'

stdout:
X
X
status=0
stderr:
toysh16 first and second word are the same alias, but no trailing space

[toysh stdout] Expected 'x echo-x\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo-x: No such file or directory
brush16 first and second word are the same alias, but no trailing space

[brush stdout] Expected 'x echo-x\n', got '$x echo-x\n'

stdout:
$x echo-x
stderr:
toysh17 first and second word are the same alias, with trailing space

[toysh stdout] Expected 'x echo x\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo-x: No such file or directory
brush17 first and second word are the same alias, with trailing space

[brush stdout] Expected 'x echo x\n', got '$x echo-x\n'

stdout:
$x echo-x
stderr:
brush18 Invalid syntax of alias

[brush status] Expected 127, got -6

stdout:
stderr: 
alias: echo --; echo: not found
Well, this is embarrassing.

brush had a problem and crashed. To help us diagnose the problem you can send us a crash report.

We have generated a report file at "/tmp/report-e879da65-c4cf-4617-a378-a9f2bb3d9383.toml". Submit an issue or email with the subject of "brush Crash Report" and include the report as an attachment.


To submit the crash report:

please post a GitHub issue at https://github.com/reubeno/brush/issues/new

We take privacy seriously, and do not perform any automated error collection. In order to improve the software, we rely on people to submit reports.

Thank you kindly!
toysh19 Dynamic alias definition

[toysh stdout] Expected 'X\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo_alias_: No such file or directory
ksh20 Alias name with punctuation

[ksh stdout] Expected 'X\n', got ''
[ksh status] Expected 0, got 127

stdout:
stderr: 
E: ksh: <stdin>[1]: shopt: inaccessible or not found
E: ksh: <stdin>[2]: alias: e_+.~x: invalid alias name
E: ksh: <stdin>[3]: e_+.~x: inaccessible or not found
toysh20 Alias name with punctuation

[toysh stdout] Expected 'X\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_+.~x: No such file or directory
zsh21 Syntax error after expansion

stdout:
stderr: 
zsh: command not found: shopt
zsh: parse error near `;;'
mksh21 Syntax error after expansion

stdout:
stderr: 
mksh: <stdin>[1]: shopt: not found
mksh: <stdin>[3]: syntax error: ';;' unexpected
ksh21 Syntax error after expansion

[ksh status] Expected 2, got 1

stdout:
stderr: 
E: ksh: <stdin>[1]: shopt: inaccessible or not found
E: ksh: <stdin>[3]: syntax error: unexpected ';;'
toysh21 Syntax error after expansion

[toysh status] Expected 2, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
sush21 Syntax error after expansion

[sush status] Expected 2, got 0

stdout:
stderr: 
brush21 Syntax error after expansion

[brush status] Expected 2, got 127

stdout:
stderr: 
;;: command not found
toysh22 Loop split across alias and arg works

[toysh stdout] Expected '1\n2\n3\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
sush22 Loop split across alias and arg works

[sush stdout] Expected '1\n2\n3\n', got ''
[sush status] Expected 0, got 2

stdout:
stderr: 
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: Unexpected token: do
brush22 Loop split across alias and arg works

[brush stdout] Expected '1\n2\n3\n', got ''
[brush status] Expected 0, got 127

stdout:
stderr: 
for: command not found
toysh23 Loop split across alias in another way

[toysh stdout] Expected '1\n2\n3\n', got ''
[toysh status] Expected 0, got 2

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
main: line 3: sh: syntax error: done
sush23 Loop split across alias in another way

[sush stdout] Expected '1\n2\n3\n', got ''
[sush status] Expected 0, got 2

stdout:
stderr: 
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: Unexpected token: do
brush23 Loop split across alias in another way

[brush stdout] Expected '1\n2\n3\n', got ''
[brush status] Expected 0, got 2

stdout:
stderr: 
ERROR main: syntax error near token `
' (line 1 col 12)
osh23 Loop split across alias in another way

stdout:
stderr: 
  for i in 1 2 3; do echo $i
                            ^
[ expansion of alias 'e_' ]:1: Expected word type Id.KW_Done, got Id.Eof_Real
zsh24 Loop split across both iterative and recursive aliases

stdout:
stderr: 
zsh: command not found: shopt
toysh24 Loop split across both iterative and recursive aliases

[toysh stdout] Expected '1\n2\n3\n', got ''
[toysh status] Expected 0, got 2

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
main: line 9: sh: syntax error: do
sush24 Loop split across both iterative and recursive aliases

[sush stdout] Expected '1\n2\n3\n', got ''
[sush status] Expected 0, got 2

stdout:
stderr: 
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 10: Unexpected token: do
brush24 Loop split across both iterative and recursive aliases

[brush stdout] Expected '1\n2\n3\n', got ''
[brush status] Expected 0, got 2

stdout:
stderr: 
ERROR main: syntax error near token `echo' (line 1 col 27)
osh24 Loop split across both iterative and recursive aliases

stdout:
stderr: 
  for i in $one "2" 3
                     ^
[ expansion of alias 'FOR1' ]:1: Invalid word in for loop
zsh25 Alias with a quote in the middle is a syntax error

stdout:
stderr: 
zsh: command not found: shopt
zsh: unmatched '
mksh25 Alias with a quote in the middle is a syntax error

stdout:
stderr: 
mksh: <stdin>[1]: shopt: not found
mksh: <stdin>[5]: no closing quote
ksh25 Alias with a quote in the middle is a syntax error

[ksh status] Expected 2, got 1

stdout:
stderr: 
E: ksh: <stdin>[1]: shopt: inaccessible or not found
E: ksh: <stdin>[5]: no closing quote
toysh25 Alias with a quote in the middle is a syntax error

[toysh status] Expected 2, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
sush25 Alias with a quote in the middle is a syntax error

[sush status] Expected 2, got 0

stdout:
${var}"
stderr:
brush25 Alias with a quote in the middle is a syntax error

[brush status] Expected 2, got 0

stdout:
" ${var}"
stderr:
toysh26 Alias with internal newlines

[toysh stdout] Expected '1\n2\n3 echo foo\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
brush26 Alias with internal newlines

[brush stdout] Expected '1\n2\n3 echo foo\n', got '1 echo 2 echo 3 echo foo\n'

stdout:
1 echo 2 echo 3 echo foo
stderr:
zsh27 Alias trailing newline

stdout:
1
2
3
stderr:
zsh: command not found: shopt
zsh: command not found: echo foo
toysh27 Alias trailing newline

[toysh stdout] Expected '1\n2\n3\nfoo\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
brush27 Alias trailing newline

[brush stdout] Expected '1\n2\n3\nfoo\n', got '1 echo 2 echo 3 echo foo\n'

stdout:
1 echo 2 echo 3 echo foo
stderr:
toysh28 Two aliases in pipeline

[toysh stdout] Expected '3\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: SEQ: No such file or directory
sh: WC: No such file or directory
brush28 Two aliases in pipeline

[brush stdout] Expected '3\n', got '0\n'

stdout:
0
stderr:
seq: invalid floating point argument: ‘THREE’
Try 'seq --help' for more information.
toysh30 Alias can be defined and used on a single line

[toysh stdout] Expected 'hello other line\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: sayhi: No such file or directory
sh: sayhi: No such file or directory
brush30 Alias can be defined and used on a single line

[brush stdout] Expected 'hello other line\n', got 'hello same line\nhello other line\n'

stdout:
hello same line
hello other line
stderr:
zsh31 Alias is respected inside eval

stdout:
hello outside
stderr:
zsh: command not found: shopt
zsh: command not found: sayhi
toysh31 Alias is respected inside eval

[toysh stdout] Expected 'hello inside\nhello outside\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: sayhi: No such file or directory
sh: sayhi: No such file or directory
sush31 Alias is respected inside eval

[sush stdout] Expected 'hello inside\nhello outside\n', got 'hello outside\n'

stdout:
hello outside
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: sayhi: command not found
toysh32 alias with redirects works

[toysh stdout] Expected '1\n2\n3\n', got ''

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
sh: e_: No such file or directory
sh: e_: No such file or directory
toysh33 alias with environment bindings works

[toysh stdout] Expected '1\n2\n', got '1\n'
[toysh status] Expected 0, got 127

stdout:
1
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: p_: No such file or directory
toysh34 alias with line continuation in the middle

[toysh stdout] Expected 'ONE TWO ONE TWO THREE two one\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: alias: No such file or directory
sh: e_: No such file or directory
brush34 alias with line continuation in the middle

[brush stdout] Expected 'ONE TWO ONE TWO THREE two one\n', got 'one\n'
[brush status] Expected 0, got 127

stdout:
one
stderr:
TWO: command not found
TWO: command not found
ONE: command not found
toysh35 alias for left brace

[toysh stdout] Expected 'one\ntwo\n', got ''
[toysh status] Expected 0, got 2

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
main: line 3: sh: syntax error: }
sush35 alias for left brace

[sush stdout] Expected 'one\ntwo\n', got ''
[sush status] Expected 0, got 2

stdout:
stderr: 
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: Unexpected token: }

brush35 alias for left brace

[brush stdout] Expected 'one\ntwo\n', got ''
[brush status] Expected 0, got 2

stdout:
stderr: 
ERROR main: syntax error near token `
' (line 1 col 27)
osh35 alias for left brace

stdout:
stderr: 
  { echo one
            ^
[ expansion of alias 'LEFT' ]:1: Expected word type Id.Lit_RBrace, got Id.Eof_Real
toysh36 alias for left paren

[toysh stdout] Expected 'one\ntwo\n', got ''
[toysh status] Expected 0, got 2

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
main: line 3: sh: syntax error: )
sush36 alias for left paren

[sush stdout] Expected 'one\ntwo\n', got ''

stdout:
stderr: 
brush36 alias for left paren

[brush stdout] Expected 'one\ntwo\n', got ''
[brush status] Expected 0, got 2

stdout:
stderr: 
ERROR main: syntax error near token `)' (line 1 col 25)
osh36 alias for left paren

stdout:
stderr: 
  ( echo one
            ^
[ expansion of alias 'LEFT' ]:1: Expected word type Id.Right_Subshell, got Id.Eof_Real
toysh37 alias used in subshell and command sub

[toysh stdout] Expected '[ subshell\n[ commandsub\n', got '\n'

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo_: No such file or directory
sh: echo_: No such file or directory
toysh38 alias used in here doc

[toysh stdout] Expected '[ ]\n', got '\n'

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: echo_: No such file or directory
bash39 here doc inside alias

stdout:
stderr: 
bash: line 6: warning: here-document at line 6 delimited by end-of-file (wanted `EOF')
bash: line 6: hi: command not found
bash: line 6: EOF: command not found
toysh39 here doc inside alias

[toysh stdout] Expected 'hi\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: c: No such file or directory
sush39 here doc inside alias

[sush stdout] Expected 'hi\n', got ''
[sush status] Expected 0, got 2

stdout:
stderr: 
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: syntax error: unexpected end of file
brush39 here doc inside alias

[brush stdout] Expected 'hi\n', got ''
[brush status] Expected 0, got 1

stdout:
stderr: 
cat: '<<EOF': No such file or directory
cat: '$(echo': No such file or directory
cat: 'hi)': No such file or directory
cat: EOF: No such file or directory
dash40 Corner case: alias inside LHS array arithmetic expression

stdout:
stderr: 
dash: 1: shopt: not found
dash: 3: a[0]=ZERO: not found
dash: 4: a[1]=ONE: not found
dash: 5: Bad substitution
ash40 Corner case: alias inside LHS array arithmetic expression

[ash stdout] Expected "['ZERO', 'ONE']\n", got ''
[ash status] Expected 0, got 2

stdout:
stderr: 
ash: shopt: not found
ash: a[0]=ZERO: not found
ash: a[1]=ONE: not found
ash: syntax error: bad substitution
zsh40 Corner case: alias inside LHS array arithmetic expression

stdout:
stderr: 
zsh: command not found: shopt
zsh: not an identifier: a[$(zeroech
toysh40 Corner case: alias inside LHS array arithmetic expression

[toysh stdout] Expected "['ZERO', 'ONE']\n", got "['']\n"

stdout:
['']
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: zero: No such file or directory
sh: a[]=ZERO: No such file or directory
sh: a[1]=ONE: No such file or directory
toysh41 Alias that is pipeline

[toysh stdout] Expected '3\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: t1: No such file or directory
brush41 Alias that is pipeline

[brush stdout] Expected '3\n', got 'hi|wc -c\n'

stdout:
hi|wc -c
stderr:
toysh42 Alias that is && || ;

[toysh stdout] Expected 'one\ntwo\n1\nfour\n', got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: t1: No such file or directory
brush42 Alias that is && || ;

[brush stdout] Expected 'one\ntwo\n1\nfour\n', got 'one && echo two && echo 3 | wc -l; echo four\n'

stdout:
one && echo two && echo 3 | wc -l; echo four
stderr:
toysh43 Alias and command sub (bug regression)

[toysh stdout] Expected "['foo', 'bar']\n", got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: a: No such file or directory
toysh44 Alias and arithmetic

[toysh stdout] Expected "['3']\n", got ''
[toysh status] Expected 0, got 127

stdout:
stderr: 
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: a: No such file or directory
dash45 Alias and PS4

stdout:
stderr: 
toysh45 Alias and PS4

[toysh stdout] Expected "['foo', 'bar']\n", got ''
[toysh status] Expected 0, got -6

stdout:
stderr: 
munmap_chunk(): invalid pointer
osh46 alias with keywords

stdout:
stderr: 
  
   ^
[ expansion of alias 'a' ]:1: Unexpected EOF while parsing command
toysh47 alias with word of multiple lines

[toysh stdout] Expected 'status=2\n', got 'status=127\n'

stdout:
status=127
stderr:
sh: shopt: No such file or directory
sh: alias: No such file or directory
sh: ll: No such file or directory