spec test index / oilshell.org
67 passed, 3 OK, 1 not implemented, 0 BUG, 31 failed, 0 timeouts, 0 cases skipped
osh_.py | 0 local -a [osh_.py stdout] Expected "['x', 'y', 'z']\n", got '' [osh_.py status] Expected 0, got 127 stdout: stderr: argv.py "${array[@]}" ^~~~~~~ [ stdin ]:3: 'argv.py' not found |
osh_.cc | 0 local -a [osh_.cc stdout] Expected "['x', 'y', 'z']\n", got '' [osh_.cc status] Expected 0, got 127 stdout: stderr: argv.py "${array[@]}" ^~~~~~~ [ stdin ]:3: 'argv.py' not found |
osh_.py | 1 declare -a [osh_.py stdout] Expected "['x', 'y', 'z']\n", got '' [osh_.py status] Expected 0, got 127 stdout: stderr: argv.py "${array[@]}" ^~~~~~~ [ stdin ]:2: 'argv.py' not found |
osh_.cc | 1 declare -a [osh_.cc stdout] Expected "['x', 'y', 'z']\n", got '' [osh_.cc status] Expected 0, got 127 stdout: stderr: argv.py "${array[@]}" ^~~~~~~ [ stdin ]:2: 'argv.py' not found |
osh | 2 indexed LHS with spaces (not allowed in OSH) stdout: status=127 []stderr: a[1 * 1]=x a[ 1 + 2 ]=z ^~ [ stdin ]:1: 'a[1' not found |
osh_.py | 2 indexed LHS with spaces (not allowed in OSH) [osh_.py stdout] Expected 'status=127\n[]\n', got 'status=127\n' [osh_.py status] Expected 0, got 127 stdout: status=127stderr: a[1 * 1]=x a[ 1 + 2 ]=z ^~ [ stdin ]:1: 'a[1' not found argv.py "${a[@]}" ^~~~~~~ [ stdin ]:3: 'argv.py' not found |
osh_.cc | 2 indexed LHS with spaces (not allowed in OSH) [osh_.cc stdout] Expected 'status=127\n[]\n', got 'status=127\n' [osh_.cc status] Expected 0, got 127 stdout: status=127stderr: a[1 * 1]=x a[ 1 + 2 ]=z ^~ [ stdin ]:1: 'a[1' not found argv.py "${a[@]}" ^~~~~~~ [ stdin ]:3: 'argv.py' not found |
osh_.cc | 3 declare -f exit code indicates function existence [osh_.cc stdout] Expected '1\n1\n0\n', got '1\n' [osh_.cc status] Expected 0, got -6 stdout: 1stderr: osh_eval.dbg: cpp/posix.h:139: void posix::dup2(int, int): Assertion `0' failed. |
osh_.cc | 5 declare -p var (exit status) [osh_.cc stdout] Expected '1\n1\n0\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:139: void posix::dup2(int, int): Assertion `0' failed. |
osh_.cc | 6 declare [osh_.cc stdout] Expected '[declare]\ntest_var1=111\ntest_var2=222\ntest_var3=333\ntest_var4=test_var1\ntest_var5=555\n[readonly]\ndeclare -r test_var2=222\n[export]\ndeclare -x test_var3=333\n[local]\ntest_var5=555\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 7 declare -p [osh_.cc stdout] Expected '[declare]\ndeclare -- test_var1=111\ndeclare -r test_var2=222\ndeclare -x test_var3=333\ndeclare -n test_var4=test_var1\ndeclare -- test_var5=555\n[readonly]\ndeclare -r test_var2=222\n[export]\ndeclare -x test_var3=333\n[local]\ndeclare -- test_var5=555\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 8 declare -p var [osh_.cc stdout] Expected '[declare]\ndeclare -- test_var1=111\ndeclare -r test_var2=222\ndeclare -x test_var3=333\ndeclare -n test_var4=test_var1\ndeclare -- test_var5=555\n[readonly]\ndeclare -r test_var2=222\n[export]\ndeclare -x test_var3=333\n[local]\ndeclare -- test_var5=555\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 10 declare -p foo=bar doesn't make sense [osh_.cc stdout] Expected 'status=1\nstatus=1\ndeclare -- a=b\n', got 'status=1\n' [osh_.cc status] Expected 0, got -6 stdout: status=1stderr: osh_eval.dbg: cpp/posix.h:139: void posix::dup2(int, int): Assertion `0' failed. |
osh_.cc | 11 declare -pnrx [osh_.cc stdout] Expected '[declare -pn]\ndeclare -n test_var4=test_var1\n[declare -pr]\ndeclare -r test_var2=222\n[declare -px]\ndeclare -x test_var3=333\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 12 declare -paA [osh_.cc stdout] Expected '[declare -pa]\ndeclare -a test_var6=()\n[declare -pA]\ndeclare -A test_var7\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 13 declare -pnrx var [osh_.cc stdout] Expected '[declare -pn]\ndeclare -n test_var4=test_var1\n[declare -pr]\ndeclare -r test_var2=222\n[declare -px]\ndeclare -x test_var3=333\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 14 declare -pg [osh_.cc stdout] Expected 'declare -- test_var1=global\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 15 declare -pg var [osh_.cc stdout] Expected 'declare -- test_var1=global\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 16 ble.sh: eval -- "$(declare -p var arr)" [osh_.cc stdout] Expected 'sum=21\narr[0]=a2\narr[1]=a5\narr[2]=a8\narr[3]=a10\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 17 eval -- "$(declare -p arr)" (restore arrays w/ unset elements) [osh_.cc stdout] Expected 'arr[0]: unset\narr[1]: unset\narr[2]: unset\narr[3]: set ... []\narr[4]: set ... [foo]\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:106: Tuple2<int, int> posix::pipe(): Assertion `0' failed. |
osh_.cc | 18 typeset -f [osh_.cc stdout] Expected '1\n1\n0\n', got '1\n' [osh_.cc status] Expected 0, got -6 stdout: 1stderr: osh_eval.dbg: cpp/posix.h:139: void posix::dup2(int, int): Assertion `0' failed. |
osh_.cc | 19 typeset -p [osh_.cc stdout] Expected '1\n1\n0\n', got '' [osh_.cc status] Expected 0, got -6 stdout: stderr: osh_eval.dbg: cpp/posix.h:139: void posix::dup2(int, int): Assertion `0' failed. |
osh_.py | 22 typeset -x makes it exported [osh_.py stdout] Expected 'lib/\n', got '' [osh_.py status] Expected 0, got 127 stdout: stderr: printenv.py PYTHONPATH ^~~~~~~~~~~ [ stdin ]:2: 'printenv.py' not found |
osh_.cc | 22 typeset -x makes it exported [osh_.cc stdout] Expected 'lib/\n', got '' [osh_.cc status] Expected 0, got 127 stdout: stderr: printenv.py PYTHONPATH ^~~~~~~~~~~ [ stdin ]:2: 'printenv.py' not found |
osh_.py | 26 declare -g (bash-specific; bash-completion uses it) [osh_.py stdout] Expected "['42', '']\n['bar', '']\n['ev2']\n", got '' [osh_.py status] Expected 0, got 127 stdout: stderr: argv.py "$G" "$L" ^~~~~~~ [ stdin ]:12: 'argv.py' not found argv.py "${dict["foo"]}" "${localdict["spam"]}" ^~~~~~~ [ stdin ]:13: 'argv.py' not found argv.py "${ev["ev1"]}" ^~~~~~~ [ stdin ]:14: 'argv.py' not found |
osh_.cc | 26 declare -g (bash-specific; bash-completion uses it) [osh_.cc stdout] Expected "['42', '']\n['bar', '']\n['ev2']\n", got '' [osh_.cc status] Expected 0, got 127 stdout: stderr: argv.py "$G" "$L" ^~~~~~~ [ stdin ]:12: 'argv.py' not found argv.py "${dict["foo"]}" "${localdict["spam"]}" ^~~~~~~ [ stdin ]:13: 'argv.py' not found argv.py "${ev["ev1"]}" ^~~~~~~ [ stdin ]:14: 'argv.py' not found |
osh | 27 myvar=typeset (another form of dynamic assignment) stdout: a bstderr: |
osh_.py | 27 myvar=typeset (another form of dynamic assignment) stdout: a bstderr: |
osh_.cc | 27 myvar=typeset (another form of dynamic assignment) stdout: a bstderr: |
osh_.py | 28 dynamic array parsing is not allowed [osh_.py stdout] Expected "status=2\n['']\n", got 'status=2\n' [osh_.py status] Expected 0, got 127 stdout: status=2stderr: typeset -a "$code" # note: -a flag is required ^ [ stdin ]:2: 'typeset' Got -a but RHS isn't an array argv.py "$x" ^~~~~~~ [ stdin ]:4: 'argv.py' not found |
osh_.cc | 28 dynamic array parsing is not allowed [osh_.cc stdout] Expected "status=2\n['']\n", got 'status=2\n' [osh_.cc status] Expected 0, got 127 stdout: status=2stderr: typeset -a "$code" # note: -a flag is required ^ [ stdin ]:2: 'typeset' Got -a but RHS isn't an array argv.py "$x" ^~~~~~~ [ stdin ]:4: 'argv.py' not found |
osh_.py | 29 dynamic flag in array in assign builtin [osh_.py stdout] Expected 'foo=F\nbar=B\nF\nB\n', got 'foo=F\nbar=B\n' [osh_.py status] Expected 0, got 127 stdout: foo=F bar=Bstderr: printenv.py foo ^~~~~~~~~~~ [ stdin ]:7: 'printenv.py' not found printenv.py bar ^~~~~~~~~~~ [ stdin ]:8: 'printenv.py' not found |
osh_.cc | 29 dynamic flag in array in assign builtin [osh_.cc stdout] Expected 'foo=F\nbar=B\nF\nB\n', got 'foo=F\nbar=B\n' [osh_.cc status] Expected 0, got 127 stdout: foo=F bar=Bstderr: printenv.py foo ^~~~~~~~~~~ [ stdin ]:7: 'printenv.py' not found printenv.py bar ^~~~~~~~~~~ [ stdin ]:8: 'printenv.py' not found |
osh_.py | 30 typeset +x [osh_.py stdout] Expected 'E\nNone\n', got '' [osh_.py status] Expected 0, got 127 stdout: stderr: printenv.py e ^~~~~~~~~~~ [ stdin ]:2: 'printenv.py' not found printenv.py e # no longer exported ^~~~~~~~~~~ [ stdin ]:4: 'printenv.py' not found |
osh_.cc | 30 typeset +x [osh_.cc stdout] Expected 'E\nNone\n', got '' [osh_.cc status] Expected 0, got 127 stdout: stderr: printenv.py e ^~~~~~~~~~~ [ stdin ]:2: 'printenv.py' not found printenv.py e # no longer exported ^~~~~~~~~~~ [ stdin ]:4: 'printenv.py' not found |