case | dash | bash | mksh | osh | description |
0 | pass | ok | ok | FAIL | Bad env name: hyphen |
details | details | details | |||
1 | pass | ok | ok | FAIL | Bad env name: period |
details | details | details | |||
2 | pass | pass | pass | pass | Bad var sub |
3 | pass | ok | ok | FAIL | Bad braced var sub -- not allowed |
details | details | details | |||
4 | BUG | BUG | BUG | FAIL | Bad var sub caught at parse time |
details | details | details | details | ||
5 | pass | pass | pass | pass | Pipe with while |
6 | pass | pass | pass | pass | Length of length of ARGS! |
7 | pass | pass | pass | pass | Length of length of ARGS! 2 digit |
8 | pass | pass | pass | FAIL | $1 .. $9 are scoped, while $0 is not |
details | |||||
9 | pass | pass | pass | pass | Chained && and || -- || has higher precedence? |
10 | pass | pass | pass | pass | Pipeline comments |
11 | pass | pass | pass | pass | Command block |
12 | ok | pass | ok | FAIL | { is its own word, needs a space |
details | details | details |
35 passed, 8 ok, 0 known unimplemented, 3 known bugs, 6 failed, 0 skipped
bash | 0 Bad env name: hyphen stdout: stderr: /bin/bash: line 1: export: `FOO-BAR=foo': not a valid identifier |
mksh | 0 Bad env name: hyphen stdout: stderr: /bin/mksh: <stdin>[1]: export: FOO-BAR=foo: is not an identifier |
osh | 0 Bad env name: hyphen [osh status] Expected 2, got 1 stdout: stderr: Traceback (most recent call last): File "bin/osh", line 378, in <module> sys.exit(main(sys.argv)) File "bin/osh", line 368, in main return OshMain(main_argv) File "bin/osh", line 327, in OshMain status, cflow = ex.Execute(node) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 739, in Execute ok, val = self.ev.EvalCompoundWord(pair.rhs) File "/home/andy/git/oil/bin/../core/word_eval.py", line 573, in EvalCompoundWord assert isinstance(word, ast.CompoundWord), "Expected CompoundWord, got %s" % word AssertionError: Expected CompoundWord, got None |
bash | 1 Bad env name: period stdout: stderr: /bin/bash: line 1: export: `FOO.BAR=foo': not a valid identifier |
mksh | 1 Bad env name: period stdout: stderr: /bin/mksh: <stdin>[1]: export: FOO.BAR=foo: is not an identifier |
osh | 1 Bad env name: period [osh status] Expected 2, got 1 stdout: stderr: Traceback (most recent call last): File "bin/osh", line 378, in <module> sys.exit(main(sys.argv)) File "bin/osh", line 368, in main return OshMain(main_argv) File "bin/osh", line 327, in OshMain status, cflow = ex.Execute(node) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 739, in Execute ok, val = self.ev.EvalCompoundWord(pair.rhs) File "/home/andy/git/oil/bin/../core/word_eval.py", line 573, in EvalCompoundWord assert isinstance(word, ast.CompoundWord), "Expected CompoundWord, got %s" % word AssertionError: Expected CompoundWord, got None |
bash | 3 Bad braced var sub -- not allowed stdout: stderr: /bin/bash: line 1: ${%}: bad substitution |
mksh | 3 Bad braced var sub -- not allowed stdout: stderr: /bin/mksh: <stdin>[1]: ${%}: bad substitution |
osh | 3 Bad braced var sub -- not allowed [osh status] Expected 2, got 1 stdout: stderr: Traceback (most recent call last): File "bin/osh", line 378, in <module> sys.exit(main(sys.argv)) File "bin/osh", line 368, in main return OshMain(main_argv) File "bin/osh", line 286, in OshMain node = c_parser.ParseWholeFile() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1561, in ParseWholeFile node = self.ParseCommandTerm() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1469, in ParseCommandTerm child = self.ParseAndOr() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1334, in ParseAndOr left = self.ParsePipeline() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1270, in ParsePipeline child = self.ParseCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1252, in ParseCommand return self.ParseSimpleCommand() # echo foo File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 599, in ParseSimpleCommand result = self._ScanSimpleCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 414, in _ScanSimpleCommand if not self._Peek(): return None File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 144, in _Peek w = self.w_parser.ReadWord(self.next_lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 1093, in ReadWord w, need_more = self._ReadWord(lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 1054, in _ReadWord w = self._ReadCompoundWord(lex_mode=lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 900, in _ReadCompoundWord part = self._ReadLeftParts() File "/home/andy/git/oil/bin/../osh/word_parse.py", line 531, in _ReadLeftParts return self._ReadBracedBracedVarSub(d_quoted=False) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 457, in _ReadBracedBracedVarSub raise AssertionError(self.cur_token) AssertionError: (token id:Unknown_Tok val:"%" span_id:3) |
dash | 4 Bad var sub caught at parse time stdout: okstderr: |
bash | 4 Bad var sub caught at parse time stdout: okstderr: |
mksh | 4 Bad var sub caught at parse time stdout: okstderr: |
osh | 4 Bad var sub caught at parse time [osh status] Expected 2, got 1 stdout: stderr: Traceback (most recent call last): File "bin/osh", line 378, in <module> sys.exit(main(sys.argv)) File "bin/osh", line 368, in main return OshMain(main_argv) File "bin/osh", line 286, in OshMain node = c_parser.ParseWholeFile() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1561, in ParseWholeFile node = self.ParseCommandTerm() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1469, in ParseCommandTerm child = self.ParseAndOr() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1334, in ParseAndOr left = self.ParsePipeline() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1270, in ParsePipeline child = self.ParseCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1233, in ParseCommand node = self.ParseCompoundCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1043, in ParseCompoundCommand return self.ParseIf() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 998, in ParseIf body = self.ParseCommandList() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1539, in ParseCommandList node = self.ParseCommandTerm() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1469, in ParseCommandTerm child = self.ParseAndOr() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1334, in ParseAndOr left = self.ParsePipeline() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1270, in ParsePipeline child = self.ParseCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 1252, in ParseCommand return self.ParseSimpleCommand() # echo foo File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 599, in ParseSimpleCommand result = self._ScanSimpleCommand() File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 414, in _ScanSimpleCommand if not self._Peek(): return None File "/home/andy/git/oil/bin/../osh/cmd_parse.py", line 144, in _Peek w = self.w_parser.ReadWord(self.next_lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 1093, in ReadWord w, need_more = self._ReadWord(lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 1054, in _ReadWord w = self._ReadCompoundWord(lex_mode=lex_mode) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 900, in _ReadCompoundWord part = self._ReadLeftParts() File "/home/andy/git/oil/bin/../osh/word_parse.py", line 531, in _ReadLeftParts return self._ReadBracedBracedVarSub(d_quoted=False) File "/home/andy/git/oil/bin/../osh/word_parse.py", line 457, in _ReadBracedBracedVarSub raise AssertionError(self.cur_token) AssertionError: (token id:Unknown_Tok val:"%" span_id:15) |
osh | 8 $1 .. $9 are scoped, while $0 is not [osh stdout] Expected b'sh a b\n', got b'' stdout: stderr: Traceback (most recent call last): File "bin/osh", line 378, in <module> sys.exit(main(sys.argv)) File "bin/osh", line 368, in main return OshMain(main_argv) File "bin/osh", line 327, in OshMain status, cflow = ex.Execute(node) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 758, in Execute status, cflow = self.Execute(child) # last status wins File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 689, in Execute status, cflow = thunk.RunInParent() File "/home/andy/git/oil/bin/../core/process.py", line 369, in RunInParent return self.ex.RunFunc(self.func_node, self.argv) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 474, in RunFunc status, cflow = self.Execute(func_body) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 758, in Execute status, cflow = self.Execute(child) # last status wins File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 703, in Execute status, cflow = self.Execute(node.command) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 706, in Execute status, cflow = self._RunPipeline(node) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 610, in _RunPipeline p = self._GetProcessForNode(child) File "/home/andy/git/oil/bin/../core/cmd_exec.py", line 519, in _GetProcessForNode raise AssertionError("Error evaluating words: %s" % err) AssertionError: Error evaluating words: ['Undefined variable 0', 'Error evaluating word part (SimpleVarSub token:(token id:VSub_Number val:"$0" span_id:8))', 'Error evaluating word (CompoundWord parts:[(SimpleVarSub token:(token id:VSub_Number val:"$0" span_id:8))])'] |
dash | 12 { is its own word, needs a space stdout: stderr: /bin/dash: 1: {ls: not found |
mksh | 12 { is its own word, needs a space stdout: stderr: /bin/mksh: <stdin>[1]: syntax error: '}' unexpected |
osh | 12 { is its own word, needs a space [osh status] Expected 2, got 127 stdout: stderr: Unexpected error in execvpe('{ls', ['{ls'], ...): [Errno 2] No such file or directory: b'/home/andy/bin/{ls' |