spec test index / oilshell.org
36 passed, 0 OK, 0 not implemented, 0 BUG, 5 failed, 0 timeouts, 0 cases skipped 5 failed under osh
osh | 6 Parsing Nested Attributes nodes (bug fix) [osh stdout] Expected '', got '--- -\t2024-07-24 19:55:26.673543189 +0000\n+++ actual.txt\t2024-07-24 19:55:26.665451370 +0000\n@@ -1,3 +0,0 @@\n-{\n- "path": "LICENSE.txt"\n-}\n' stdout: --- - 2024-07-24 19:55:26.673543189 +0000 +++ actual.txt 2024-07-24 19:55:26.665451370 +0000 @@ -1,3 +0,0 @@ -{ - "path": "LICENSE.txt" -}stderr: json write (_hay()) | jq '.children[0].children[0].attrs' > actual.txt ^~ [ stdin ]:15: 'jq' not found (OILS-ERR-100) invalid = 'syntax' # parse error ^ [ stdin ]:23: Unexpected = (Hint: use var/setvar, or quote it) |
osh_ALT | 6 Parsing Nested Attributes nodes (bug fix) [osh_ALT stdout] Expected '', got '--- -\t2024-07-24 19:55:26.723701488 +0000\n+++ actual.txt\t2024-07-24 19:55:26.713451468 +0000\n@@ -1,3 +0,0 @@\n-{\n- "path": "LICENSE.txt"\n-}\n' stdout: --- - 2024-07-24 19:55:26.723701488 +0000 +++ actual.txt 2024-07-24 19:55:26.713451468 +0000 @@ -1,3 +0,0 @@ -{ - "path": "LICENSE.txt" -}stderr: json write (_hay()) | jq '.children[0].children[0].attrs' > actual.txt ^~ [ stdin ]:15: 'jq' not found (OILS-ERR-100) invalid = 'syntax' # parse error ^ [ stdin ]:23: Unexpected = (Hint: use var/setvar, or quote it) |
osh | 7 hay eval Attr node, and JSON [osh stdout] Expected 'diff 0\n', got '--- -\t2024-07-24 19:55:26.787961166 +0000\n+++ out.txt\t2024-07-24 19:55:26.777451598 +0000\n@@ -1,29 +0,0 @@\n-{\n- "source": null,\n- "children": [\n- {\n- "type": "Package",\n- "args": [\n- "foo"\n- ],\n- "children": [],\n- "attrs": {\n- "int": 42,\n- "bool": true,\n- "mynull": null,\n- "mystr": "spam\\n",\n- "mylist": [\n- 5,\n- "foo",\n- {}\n- ]\n- }\n- },\n- {\n- "type": "User",\n- "args": [\n- "alice"\n- ]\n- }\n- ]\n-}\ndiff 1\n' stdout: --- - 2024-07-24 19:55:26.787961166 +0000 +++ out.txt 2024-07-24 19:55:26.777451598 +0000 @@ -1,29 +0,0 @@ -{ - "source": null, - "children": [ - { - "type": "Package", - "args": [ - "foo" - ], - "children": [], - "attrs": { - "int": 42, - "bool": true, - "mynull": null, - "mystr": "spam\n", - "mylist": [ - 5, - "foo", - {} - ] - } - }, - { - "type": "User", - "args": [ - "alice" - ] - } - ] -} diff 1stderr: json write (result) | jq . > out.txt ^~ [ stdin ]:18: 'jq' not found (OILS-ERR-100) |
osh_ALT | 7 hay eval Attr node, and JSON [osh_ALT stdout] Expected 'diff 0\n', got '--- -\t2024-07-24 19:55:26.839941170 +0000\n+++ out.txt\t2024-07-24 19:55:26.829451703 +0000\n@@ -1,29 +0,0 @@\n-{\n- "source": null,\n- "children": [\n- {\n- "type": "Package",\n- "args": [\n- "foo"\n- ],\n- "children": [],\n- "attrs": {\n- "int": 42,\n- "bool": true,\n- "mynull": null,\n- "mystr": "spam\\n",\n- "mylist": [\n- 5,\n- "foo",\n- {}\n- ]\n- }\n- },\n- {\n- "type": "User",\n- "args": [\n- "alice"\n- ]\n- }\n- ]\n-}\ndiff 1\n' stdout: --- - 2024-07-24 19:55:26.839941170 +0000 +++ out.txt 2024-07-24 19:55:26.829451703 +0000 @@ -1,29 +0,0 @@ -{ - "source": null, - "children": [ - { - "type": "Package", - "args": [ - "foo" - ], - "children": [], - "attrs": { - "int": 42, - "bool": true, - "mynull": null, - "mystr": "spam\n", - "mylist": [ - 5, - "foo", - {} - ] - } - }, - { - "type": "User", - "args": [ - "alice" - ] - } - ] -} diff 1stderr: json write (result) | jq . > out.txt ^~ [ stdin ]:18: 'jq' not found (OILS-ERR-100) |
osh | 8 hay eval shell node, and JSON [osh stdout] Expected '', got '--- -\t2024-07-24 19:55:26.902005846 +0000\n+++ out.txt\t2024-07-24 19:55:26.893451833 +0000\n@@ -1,19 +0,0 @@\n-{\n- "source": null,\n- "children": [\n- {\n- "type": "TASK",\n- "args": [],\n- "location_str": "[ stdin ]",\n- "location_start_line": 6,\n- "code_str": " echo hi "\n- },\n- {\n- "type": "TASK",\n- "args": [],\n- "location_str": "[ stdin ]",\n- "location_start_line": 8,\n- "code_str": " \\n echo one\\n echo two\\n "\n- }\n- ]\n-}\n' [osh status] Expected 0, got 1 stdout: --- - 2024-07-24 19:55:26.902005846 +0000 +++ out.txt 2024-07-24 19:55:26.893451833 +0000 @@ -1,19 +0,0 @@ -{ - "source": null, - "children": [ - { - "type": "TASK", - "args": [], - "location_str": "[ stdin ]", - "location_start_line": 6, - "code_str": " echo hi " - }, - { - "type": "TASK", - "args": [], - "location_str": "[ stdin ]", - "location_start_line": 8, - "code_str": " \n echo one\n echo two\n " - } - ] -}stderr: json write (result) | jq . > out.txt ^~ [ stdin ]:14: 'jq' not found (OILS-ERR-100) |
osh_ALT | 8 hay eval shell node, and JSON [osh_ALT stdout] Expected '', got '--- -\t2024-07-24 19:55:26.952661431 +0000\n+++ out.txt\t2024-07-24 19:55:26.945451938 +0000\n@@ -1,19 +0,0 @@\n-{\n- "source": null,\n- "children": [\n- {\n- "type": "TASK",\n- "args": [],\n- "location_str": "[ stdin ]",\n- "location_start_line": 6,\n- "code_str": " echo hi "\n- },\n- {\n- "type": "TASK",\n- "args": [],\n- "location_str": "[ stdin ]",\n- "location_start_line": 8,\n- "code_str": " \\n echo one\\n echo two\\n "\n- }\n- ]\n-}\n' [osh_ALT status] Expected 0, got 1 stdout: --- - 2024-07-24 19:55:26.952661431 +0000 +++ out.txt 2024-07-24 19:55:26.945451938 +0000 @@ -1,19 +0,0 @@ -{ - "source": null, - "children": [ - { - "type": "TASK", - "args": [], - "location_str": "[ stdin ]", - "location_start_line": 6, - "code_str": " echo hi " - }, - { - "type": "TASK", - "args": [], - "location_str": "[ stdin ]", - "location_start_line": 8, - "code_str": " \n echo one\n echo two\n " - } - ] -}stderr: json write (result) | jq . > out.txt ^~ [ stdin ]:14: 'jq' not found (OILS-ERR-100) |
osh | 21 Typed Args to Hay Node [osh status] Expected 0, got 1 stdout: stderr: when NAME (x > 0) { ^ [ stdin ]:6: fatal: Undefined variable 'x' |
osh_ALT | 21 Typed Args to Hay Node [osh_ALT status] Expected 0, got 1 stdout: stderr: when NAME (x > 0) { ^ [ stdin ]:6: fatal: Undefined variable 'x' |
osh | 22 OSH and hay (dynamic parsing) [osh stdout] Expected "backticks\neval\nTYPE TASK\nCODE \n echo `echo task backticks`\n eval 'echo task eval'\n ___\n" Got '' [osh status] Expected 0, got 2 stdout: stderr: b[1]=1 ^~ /home/uke/oil/spec/testdata/config/osh-hay.osh:14: Use var/setvar to assign in YSH source $REPO_ROOT/spec/testdata/config/osh-hay.osh ^~~~~~ [ stdin ]:1: errexit PID 31438: command.Simple failed with status 2 |
osh_ALT | 22 OSH and hay (dynamic parsing) [osh_ALT stdout] Expected "backticks\neval\nTYPE TASK\nCODE \n echo `echo task backticks`\n eval 'echo task eval'\n ___\n" Got '' [osh_ALT status] Expected 0, got 2 stdout: stderr: b[1]=1 ^~ /home/uke/oil/test/../spec/testdata/config/osh-hay.osh:14: Use var/setvar to assign in YSH source $REPO_ROOT/spec/testdata/config/osh-hay.osh ^~~~~~ [ stdin ]:1: errexit PID 31441: command.Simple failed with status 2 |