Results for errexit.test.sh

statusbashmkshkshtoyshsushbrushosh
pass 34353513121435
BUG 1000000
FAIL 0002223210
total35353535353535
casebashmkshkshtoyshsushbrushoshdescription
0pass pass pass FAIL FAIL FAIL pass errexit aborts early
detailsdetailsdetails
1pass pass pass FAIL FAIL FAIL pass errexit for nonexistent command
detailsdetailsdetails
2pass pass pass FAIL FAIL FAIL pass errexit aborts early on pipeline
detailsdetailsdetails
3pass pass pass FAIL FAIL FAIL pass errexit with { }
detailsdetailsdetails
4pass pass pass pass pass pass pass errexit with if and { }
5pass pass pass pass pass pass pass errexit with ||
6pass pass pass pass pass pass pass errexit with &&
7pass pass pass pass pass pass pass errexit test && -- from gen-module-init
8pass pass pass FAIL FAIL FAIL pass errexit test && and fail
detailsdetailsdetails
9pass pass pass FAIL pass FAIL pass More && ||
detailsdetails
10pass pass pass pass pass pass pass errexit and loop
11pass pass pass pass pass pass pass errexit and brace group { }
12pass pass pass FAIL FAIL FAIL pass errexit and time { }
detailsdetailsdetails
13pass pass pass pass pass pass pass errexit with !
14pass pass pass pass pass pass pass errexit with ! and ;
15pass pass pass pass FAIL pass pass errexit with while/until
details
16pass pass pass FAIL FAIL FAIL pass errexit with (( ))
detailsdetailsdetails
17pass pass pass FAIL FAIL FAIL pass errexit with subshell
detailsdetailsdetails
18pass pass pass FAIL FAIL FAIL pass set -o errexit while it's being ignored (moot with strict_errexit)
detailsdetailsdetails
19pass pass pass pass pass pass pass set +o errexit while it's being ignored (moot with strict_errexit)
20pass pass pass pass pass pass pass set +o errexit with 2 levels of ignored
21pass pass pass FAIL FAIL FAIL pass setting errexit in a subshell works but doesn't affect parent shell
detailsdetailsdetails
22pass pass pass FAIL FAIL FAIL pass set errexit while it's ignored in a subshell (moot with strict_errexit)
detailsdetailsdetails
23pass pass pass FAIL FAIL FAIL pass shopt -s strict:all || true while errexit is on
detailsdetailsdetails
24pass pass pass FAIL FAIL FAIL pass errexit double guard
detailsdetailsdetails
25pass pass pass FAIL FAIL FAIL pass background processes respect errexit
detailsdetailsdetails
26pass pass pass FAIL FAIL FAIL pass pipeline process respects errexit
detailsdetailsdetails
27pass pass pass FAIL FAIL FAIL pass simple command / assign - redir failure DOES respect errexit
detailsdetailsdetails
28pass pass pass FAIL FAIL FAIL pass simple command that's an alias - redir failure checked
detailsdetailsdetails
29pass pass pass FAIL FAIL FAIL pass bash atoms [[ (( - redir failure checked
detailsdetailsdetails
30pass pass pass FAIL FAIL FAIL pass brace group - redir failure checked
detailsdetailsdetails
31pass pass pass FAIL FAIL FAIL pass while loop - redirect failure checked
detailsdetailsdetails
32pass pass pass pass FAIL pass pass set -e enabled in function (regression)
details
33BUG pass pass FAIL FAIL pass pass set -e in function #2
detailsdetailsdetails
34pass pass pass pass pass pass pass Command sub exit code is lost
178 passed, 0 OK, 0 not implemented, 1 BUG, 66 failed, 0 timeouts, 0 cases skipped

Details on runs that didn't PASS

toysh0 errexit aborts early

[toysh stdout] Expected u'', got 'done\n'
[toysh status] Expected 1, got 0

stdout:
done
stderr:
set: bad -o errexit
sush0 errexit aborts early

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

stdout:
done
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush0 errexit aborts early

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

stdout:
done
stderr:
toysh1 errexit for nonexistent command

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

stdout:
done
stderr:
set: bad -o errexit
sh: nonexistent__ZZ: No such file or directory
sush1 errexit for nonexistent command

[sush stdout] Expected u'', got 'done\n'
[sush status] Expected 127, got 0

stdout:
done
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: nonexistent__ZZ: command not found
brush1 errexit for nonexistent command

[brush stdout] Expected u'', got 'done\n'
[brush status] Expected 127, got 0

stdout:
done
stderr:
nonexistent__ZZ: command not found
toysh2 errexit aborts early on pipeline

[toysh stdout] Expected u'', got 'two\n'
[toysh status] Expected 1, got 0

stdout:
two
stderr:
set: bad -o errexit
sush2 errexit aborts early on pipeline

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

stdout:
two
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush2 errexit aborts early on pipeline

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

stdout:
two
stderr:
toysh3 errexit with { }

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

stdout:
one
two
stderr:
set: bad -o errexit
sush3 errexit with { }

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

stdout:
one
two
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush3 errexit with { }

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

stdout:
one
two
stderr:
toysh8 errexit test && and fail

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

stdout:
status=1
stderr:
set: bad -o errexit
sush8 errexit test && and fail

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

stdout:
status=1
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush8 errexit test && and fail

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

stdout:
status=1
stderr:
toysh9 More && ||

[toysh stdout] Expected 'group\nstatus=1\n\nsubshell\nstatus=42\n\nstatus=1\n' Got 'group\nbad\nstatus=0\n\nsubshell\nbad\nstatus=0\n\nbad\nstatus=0\n'

stdout:
group
bad
status=0

subshell
bad
status=0

bad
status=0
stderr:
set: bad -e
set: bad -e
set: bad -e
brush9 More && ||

[brush stdout] Expected 'group\nstatus=1\n\nsubshell\nstatus=42\n\nstatus=1\n' Got 'group\nbad\nstatus=0\n\nsubshell\nbad\nstatus=0\n\nbad\nstatus=0\n'

stdout:
group
bad
status=0

subshell
bad
status=0

bad
status=0
stderr:
toysh12 errexit and time { }

[toysh status] Expected 1, got 0

stdout:
status=1
stderr:
set: bad -o errexit

real	0.000
user	0.650
sys	0.000
sush12 errexit and time { }

[sush status] Expected 1, got 0

stdout:
status=1
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name

real	0m0.000007s
user	0m0.000008s
sys 	0m0.000000s
brush12 errexit and time { }

[brush status] Expected 1, got 0

stdout:
status=1
stderr:
real	0m0.000s
user	0m0.000s
sys	0m0.000s
sush15 errexit with while/until

[sush status] Expected 0, got 2

stdout:
ok
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 6: Unexpected token: do

sush: break: only meaningful in a `for', `while', or `until' loop
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 9: Unexpected token: done

toysh16 errexit with (( ))

[toysh stdout] Expected u'', got 'done\n'
[toysh status] Expected 1, got 0

stdout:
done
stderr:
set: bad -o errexit
sush16 errexit with (( ))

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

stdout:
done
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush16 errexit with (( ))

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

stdout:
done
stderr:
toysh17 errexit with subshell

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

stdout:
one
two
three
stderr:
set: bad -o errexit
sush17 errexit with subshell

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

stdout:
one
two
three
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush17 errexit with subshell

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

stdout:
one
two
three
stderr:
toysh18 set -o errexit while it's being ignored (moot with strict_errexit)

[toysh stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[toysh status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
set: bad -o errexit
set: bad -o errexit
sush18 set -o errexit while it's being ignored (moot with strict_errexit)

[sush stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[sush status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
brush18 set -o errexit while it's being ignored (moot with strict_errexit)

[brush stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[brush status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
toysh21 setting errexit in a subshell works but doesn't affect parent shell

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

stdout:
1
2
3
4
5
6
stderr:
set: bad -o errexit
sush21 setting errexit in a subshell works but doesn't affect parent shell

[sush stdout] Expected '1\n2\n3\n5\n6\n', got '1\n2\n3\n4\n5\n6\n'

stdout:
1
2
3
4
5
6
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush21 setting errexit in a subshell works but doesn't affect parent shell

[brush stdout] Expected '1\n2\n3\n5\n6\n', got '1\n2\n3\n4\n5\n6\n'

stdout:
1
2
3
4
5
6
stderr:
toysh22 set errexit while it's ignored in a subshell (moot with strict_errexit)

[toysh stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[toysh status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
set: bad -o errexit
set: bad -o errexit
sush22 set errexit while it's ignored in a subshell (moot with strict_errexit)

[sush stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[sush status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
brush22 set errexit while it's ignored in a subshell (moot with strict_errexit)

[brush stdout] Expected '1\n2\n3\n4\n5\n6\n', got '1\n2\n3\n4\n5\n6\n7\n'
[brush status] Expected 1, got 0

stdout:
1
2
3
4
5
6
7
stderr:
toysh23 shopt -s strict:all || true while errexit is on

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

stdout:
one
two
stderr:
set: bad -o errexit
sh: shopt: No such file or directory
sush23 shopt -s strict:all || true while errexit is on

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

stdout:
one
two
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: shopt: strict:all: not supported yet
brush23 shopt -s strict:all || true while errexit is on

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

stdout:
one
two
stderr:
shopt: strict:all: invalid shell option name
toysh24 errexit double guard

[toysh stdout] Expected 'true\n', got ''
[toysh status] Expected 1, got 2

stdout:
stderr: 
set: bad -o errexit
main: line 2: sh: syntax error: fi
sush24 errexit double guard

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

stdout:
true
done
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush24 errexit double guard

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

stdout:
true
done
stderr:
toysh25 background processes respect errexit

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

stdout:
one
two
stderr:
set: bad -o errexit
sush25 background processes respect errexit

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

stdout:
one
two
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
3699515
brush25 background processes respect errexit

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

stdout:
one
two
stderr:
toysh26 pipeline process respects errexit

[toysh stdout] Expected 'one\n[three]\n', got 'one\ntwo\nfour\n'
[toysh status] Expected 1, got 0

stdout:
one
two
four
stderr:
set: bad -o errexit
sh: read: No such file or directory
sush26 pipeline process respects errexit

[sush stdout] Expected 'one\n[three]\n', got 'one\ntwo\n[three]\n[four]\nfour\n'
[sush status] Expected 1, got 0

stdout:
one
two
[three]
[four]
four
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
brush26 pipeline process respects errexit

[brush stdout] Expected 'one\n[three]\n', got 'one\ntwo\n[three]\n[four]\nfour\n'
[brush status] Expected 1, got 0

stdout:
one
two
[three]
[four]
four
stderr:
toysh27 simple command / assign - redir failure DOES respect errexit

[toysh stdout] Expected 'status=1\nstatus=1\nstatus=1\n', got 'builtin status=1\nstatus=0\nextern status=1\nstatus=0\nassign status=1\nstatus=0\n'

stdout:
builtin status=1
status=0
extern status=1
status=0
assign status=1
status=0
stderr:
set: bad -o errexit
sh: /: Is a directory
set: bad -o errexit
sh: /: Is a directory
set: bad -o errexit
sh: /: Is a directory
sush27 simple command / assign - redir failure DOES respect errexit

[sush stdout] Expected 'status=1\nstatus=1\nstatus=1\n', got 'builtin status=1\nstatus=0\nextern status=1\nstatus=0\nassign status=2\nstatus=0\n'

stdout:
builtin status=1
status=0
extern status=1
status=0
assign status=2
status=0
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: /: is a directory
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: /: is a directory
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
brush27 simple command / assign - redir failure DOES respect errexit

[brush stdout] Expected 'status=1\nstatus=1\nstatus=1\n', got 'builtin status=1\nstatus=0\nextern status=1\nstatus=0\nassign status=1\nstatus=0\n'

stdout:
builtin status=1
status=0
extern status=1
status=0
assign status=1
status=0
stderr:
error: failed to redirect to /: Is a directory (os error 21)
error: failed to redirect to /: Is a directory (os error 21)
error: failed to redirect to /: Is a directory (os error 21)
toysh28 simple command that's an alias - redir failure checked

[toysh stdout] Expected 'status=1\n', got 'alias status=1\nstatus=0\n'

stdout:
alias status=1
status=0
stderr:
sh: shopt: No such file or directory
set: bad -o errexit
sh: alias: No such file or directory
sh: /: Is a directory
sush28 simple command that's an alias - redir failure checked

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

stdout:
alias status=2
status=0
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 7: Unexpected token: }
brush28 simple command that's an alias - redir failure checked

[brush stdout] Expected 'status=1\n', got 'alias status=1\nstatus=0\n'

stdout:
alias status=1
status=0
stderr:
error: failed to redirect to /: Is a directory (os error 21)
toysh29 bash atoms [[ (( - redir failure checked

[toysh stdout] Expected 'status=1\nstatus=1\n', got ''
[toysh status] Expected 0, got -6

stdout:
stderr: 
munmap_chunk(): invalid pointer
sush29 bash atoms [[ (( - redir failure checked

[sush stdout] Expected 'status=1\nstatus=1\n', got 'dbracket status=1\nstatus=0\ndparen status=2\nstatus=0\n'

stdout:
dbracket status=1
status=0
dparen status=2
status=0
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: /: is a directory
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 2: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 4: Unexpected token: >
brush29 bash atoms [[ (( - redir failure checked

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

stdout:
status=2
status=1
stderr:
ERROR main: syntax error near token `>' (line 3 col 13)
ERROR error: failed to redirect to /: Is a directory (os error 21)
toysh30 brace group - redir failure checked

[toysh stdout] Expected '', got 'status=1\nshould not get here\n'
[toysh status] Expected 1, got 0

stdout:
status=1
should not get here
stderr:
set: bad -o errexit
sh: not_exist.txt: No such file or directory
sush30 brace group - redir failure checked

[sush stdout] Expected '', got 'status=1\nshould not get here\n'
[sush status] Expected 1, got 0

stdout:
status=1
should not get here
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: not_exist.txt: entity not found
brush30 brace group - redir failure checked

[brush stdout] Expected '', got 'status=0\nshould not get here\n'
[brush status] Expected 1, got 0

stdout:
status=0
should not get here
stderr:
ERROR error: failed to redirect to /home/andy/git/oils-for-unix/oils/_tmp/spec-tmp/errexit.test.sh.3694610/30-brush/not_exist.txt: No such file or directory (os error 2)
toysh31 while loop - redirect failure checked

[toysh stdout] Expected '', got 'status=1\nshould not get here\n'
[toysh status] Expected 1, got 0

stdout:
status=1
should not get here
stderr:
set: bad -o errexit
sh: not_exist.txt: No such file or directory
sush31 while loop - redirect failure checked

[sush stdout] Expected '', got 'status=1\nshould not get here\n'
[sush status] Expected 1, got 0

stdout:
status=1
should not get here
stderr:
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 1: set: errexit: invalid option name
/home/andy/git/oils-for-unix/oils/../../shells/rusty_bash/target/release/sush: line 3: not_exist.txt: entity not found
brush31 while loop - redirect failure checked

[brush stdout] Expected '', got 'status=0\nshould not get here\n'
[brush status] Expected 1, got 0

stdout:
status=0
should not get here
stderr:
ERROR error: failed to redirect to /home/andy/git/oils-for-unix/oils/_tmp/spec-tmp/errexit.test.sh.3694610/31-brush/not_exist.txt: No such file or directory (os error 2)
sush32 set -e enabled in function (regression)

[sush stdout] Expected 'should be executed\nshould be executed\n', got ''
[sush status] Expected 0, got 1

stdout:
stderr: 
bash33 set -e in function #2

stdout:
stderr: 
toysh33 set -e in function #2

[toysh stdout] Expected 'should be executed\nshould be executed\n', got 'should be executed\n'

stdout:
should be executed
stderr:
sh: foo: No such file or directory
sush33 set -e in function #2

[sush stdout] Expected 'should be executed\nshould be executed\n', got ''
[sush status] Expected 0, got 1

stdout:
stderr: