spec test index / oilshell.org
status | osh | osh-cpp | |
pass | 15 | 4 | |
FAIL | 0 | 11 | |
total | 15 | 15 | |
case | osh | osh-cpp | description |
0 | pass | pass | try usage error |
1 | pass | FAIL | try sets _status |
details | |||
2 | pass | FAIL | try with and without errexit |
details | |||
3 | pass | FAIL | try takes a block |
details | |||
4 | pass | FAIL | try with _pipeline_status and PIPESTATUS |
details | |||
5 | pass | FAIL | try with _process_sub_status |
details | |||
6 | pass | FAIL | try error handling idioms |
details | |||
7 | pass | FAIL | try can handled failed var, setvar, etc. |
details | |||
8 | pass | FAIL | try can handled failed expr sub |
details | |||
9 | pass | FAIL | try with failed command sub within expression |
details | |||
10 | pass | FAIL | try allows command sub (bug #1608) |
details | |||
11 | pass | FAIL | Uncaught expression error exits status 3 |
details | |||
12 | pass | pass | boolstatus with external command |
13 | pass | pass | boolstatus disallows procs with strict_errexit |
14 | pass | pass | boolstatus can call a function without strict_errexit (not recommended) |
19 passed, 0 OK, 0 not implemented, 0 BUG, 11 failed, 0 timeouts, 0 cases skipped
osh-cpp | 1 try sets _status [osh-cpp stdout] Expected 'myproc\ndollar=0\n_status=42\ndollar=9\n_status=42\n' Got 'myproc\ndollar=0\n_status=\ndollar=9\n_status=\n' stdout: myproc dollar=0 _status= dollar=9 _status=stderr: |
osh-cpp | 2 try with and without errexit [osh-cpp stdout] Expected 'before\nstatus=1\n---\nblock\nbefore\nstatus=1\n===\nbefore\nstatus=1\n---\nblock\nbefore\nstatus=1\n' Got 'before\nstatus=\n---\nblock\nbefore\nstatus=\n===\nbefore\nstatus=\n---\nblock\nbefore\nstatus=\n' stdout: before status= --- block before status= === before status= --- block before status=stderr: |
osh-cpp | 3 try takes a block [osh-cpp stdout] Expected 'myproc\ndollar=0\n_status=42\nmyproc\ndollar=0\n_status=42\n' Got 'myproc\ndollar=0\n_status=\nmyproc\ndollar=0\n_status=\n' stdout: myproc dollar=0 _status= myproc dollar=0 _status=stderr: |
osh-cpp | 4 try with _pipeline_status and PIPESTATUS [osh-cpp stdout] Expected '0\np 2 0\np 2 0\n_status=0\n---\n0\np 2 0\np 2 0\n_status=2\n' Got '0\np 2 0\np 2 0\n_status=\n---\n0\np 2 0\np 2 0\n_status=\n' stdout: 0 p 2 0 p 2 0 _status= --- 0 p 2 0 p 2 0 _status=stderr: ls: cannot access '/bad': No such file or directory ls: cannot access '/bad': No such file or directory |
osh-cpp | 5 try with _process_sub_status [osh-cpp stdout] Expected 'p 2 0\n_status=0\n---\np 2 0\n_status=2\n', got 'p 2 0\n_status=\n---\np 2 0\n_status=\n' stdout: p 2 0 _status= --- p 2 0 _status=stderr: sort: cannot read: OOPS: No such file or directory sort: cannot read: OOPS: No such file or directory |
osh-cpp | 6 try error handling idioms [osh-cpp stdout] Expected 'fail\n0\npipeline failed: 2 0\nprocess sub failed: 2 2\n' Got '0\n' stdout: 0stderr: ls: cannot access '/nonexistent': No such file or directory sort: cannot read: YY: No such file or directory sort: cannot read: XX: No such file or directory |
osh-cpp | 7 try can handled failed var, setvar, etc. [osh-cpp stdout] Expected 'hi\ndiv 3\nindex 3\nkey 3\narrow 3\n', got 'hi\nshould not get here\ndiv\nshould not get here\nindex\nshould not get here\nkey\nshould not get here\narrow\n' stdout: hi should not get here div should not get here index should not get here key should not get here arrowstderr: |
osh-cpp | 8 try can handled failed expr sub [osh-cpp stdout] Expected 'hi\n_status=3\n', got 'hi\nresult = \nshould not get here\n_status=\n' stdout: hi result = should not get here _status=stderr: |
osh-cpp | 9 try with failed command sub within expression [osh-cpp stdout] Expected 'hi\ntry 42\n', got 'hi\nbye\ntry\n' stdout: hi bye trystderr: |
osh-cpp | 10 try allows command sub (bug #1608) [osh-cpp stdout] Expected 'hi\n', got '' [osh-cpp status] Expected 0, got 1 stdout: stderr: echo $x ^~ [ stdin ]:6: fatal: Undefined variable 'x' |
osh-cpp | 11 Uncaught expression error exits status 3 [osh-cpp stdout] Expected 'outside=3\n', got 'inside=0\noutside=0\n' stdout: inside=0 outside=0stderr: |