spec test index / oilshell.org
status | osh | osh_.py | osh_.cc | |
pass | 14 | 13 | 10 | |
ok | 1 | 1 | 1 | |
FAIL | 0 | 1 | 4 | |
total | 15 | 15 | 15 | |
case | osh | osh_.py | osh_.cc | description |
0 | pass | pass | pass | (( )) result |
1 | pass | pass | pass | negative number is true |
2 | pass | pass | pass | (( )) in if statement |
3 | pass | pass | pass | (( )) |
4 | pass | pass | pass | (( )) with arrays |
5 | pass | pass | pass | (( )) with error |
6 | pass | pass | pass | bash and mksh: V in (( a[K] = V )) gets coerced to integer |
7 | ok | ok | ok | bash: K in (( A[K] = V )) is a constant string |
details | details | details | ||
8 | pass | pass | pass | BUG: (( V = A[K] )) doesn't retrieve the right value |
9 | pass | pass | FAIL | bash: V in (( A["K"] = V )) gets coerced to integer |
details | ||||
10 | pass | pass | pass | literal strings inside (( )) |
11 | pass | FAIL | FAIL | (( )) with redirect |
details | details | |||
12 | pass | pass | pass | Can't make assign whole array to var (( b = a )) |
13 | pass | pass | FAIL | set associative array |
details | ||||
14 | pass | pass | FAIL | Example of incrementing associative array entry with var key (ble.sh) |
details |
37 passed, 3 OK, 0 not implemented, 0 BUG, 5 failed, 0 timeouts, 0 cases skipped
osh | 7 bash: K in (( A[K] = V )) is a constant string stdout: stderr: (( A[K] = V )) ^~ [ stdin ]:4: fatal: Associative array keys must be strings: $x 'x' "$x" etc. |
osh_.py | 7 bash: K in (( A[K] = V )) is a constant string stdout: stderr: (( A[K] = V )) ^~ [ stdin ]:4: fatal: Associative array keys must be strings: $x 'x' "$x" etc. |
osh_.cc | 7 bash: K in (( A[K] = V )) is a constant string stdout: stderr: (( A[K] = V )) ^~ [ stdin ]:4: fatal: Associative array keys must be strings: $x 'x' "$x" etc. |
osh_.cc | 9 bash: V in (( A["K"] = V )) gets coerced to integer [osh_.cc stdout] Expected 'A["key"]=\nkeys = K\nvalues = 0\n', got 'A["key"]=\n' [osh_.cc status] Expected 0, got -6 stdout: A["key"]=stderr: osh_eval.dbg: mycpp/mylib.h:639: List<K> *Dict<Str *, Str *>::keys() [K = Str *, V = Str *]: Assertion `0' failed. |
osh_.py | 11 (( )) with redirect [osh_.py stdout] Expected '52\n--\nSTDERR\n', got '' [osh_.py status] Expected 0, got 1 [osh_.py stderr] Found 'Traceback (most recent' stdout: stderr: Traceback (most recent call last): File "/home/andy/git/oilshell/oil/bin/osh_eval.py", line 417, in <module> status = main(sys.argv) File "/home/andy/git/oilshell/oil/bin/osh_eval.py", line 309, in main cmd_flags=cmd_eval.IsMainProgram) File "/home/andy/git/oilshell/oil/core/main_loop.py", line 168, in Batch is_return, is_fatal = cmd_ev.ExecuteAndCatch(node, cmd_flags=cmd_flags) File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 1461, in ExecuteAndCatch status = self._Execute(node) File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 1333, in _Execute status, check_errexit = self._Dispatch(node) File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 647, in _Dispatch i = self.arith_ev.EvalToInt(node.child) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 367, in EvalToInt val = self.Eval(node) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 447, in Eval rhs_int = self.EvalToInt(node.right) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 367, in EvalToInt val = self.Eval(node) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 565, in Eval lhs = self.EvalToInt(node.left) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 367, in EvalToInt val = self.Eval(node) File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 408, in Eval return self.word_ev.EvalWordToString(w) File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1498, in EvalWordToString self._EvalWordPart(p, part_vals, quoted=False) File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1332, in _EvalWordPart sv = self._EvalCommandSub(part.child, quoted) # type: part_value_t File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1959, in _EvalCommandSub stdout = self.shell_ex.RunCommandSub(node) AttributeError: 'NoneType' object has no attribute 'RunCommandSub' |
osh_.cc | 11 (( )) with redirect [osh_.cc stdout] Expected '52\n--\nSTDERR\n', got "10\n--\n(cmd_value.Argv argv:[cat '/x.txt'] arg_spids:[31 33])\n" stdout: 10 -- (cmd_value.Argv argv:[cat '/x.txt'] arg_spids:[31 33])stderr: Unhandled SimpleCommand |
osh_.cc | 13 set associative array [osh_.cc stdout] Expected '42\n', got '0\n' stdout: 0stderr: |
osh_.cc | 14 Example of incrementing associative array entry with var key (ble.sh) [osh_.cc stdout] Expected 'foo=44\n', got '' [osh_.cc status] Expected 0, got -11 stdout: stderr: set 4 |