spec test index / oilshell.org
53 passed, 0 OK, 0 not implemented, 0 BUG, 49 failed, 0 timeouts, 0 cases skipped 1 failed under osh
osh-cpp | 0 command sub $(echo hi) [osh-cpp stdout] Expected 'x=hi y=default\n', got 'x=default y=default\n' stdout: x=default y=defaultstderr: |
osh-cpp | 1 shell array %(a 'b c') [osh-cpp stdout] Expected "['/', 'a', 'b c', '/']\n", got '' [osh-cpp status] Expected 0, got 1 stdout: stderr: argv.py / @x @empty / ^~ [ stdin ]:4: fatal: Can't splice 'x' |
osh-cpp | 2 empty array and simple_word_eval (regression test) [osh-cpp stdout] Expected "len=0\n['/', '/']\n", got 'len=0\n' [osh-cpp status] Expected 0, got 1 stdout: len=0stderr: argv.py / @empty / ^~~~~~ [ stdin ]:4: fatal: Can't splice 'empty' |
osh-cpp | 4 Shell arrays support tilde detection, static globbing, brace detection [osh-cpp stdout] Expected "['/home/bob/src', 'bar.py', 'foo.py', 'andy@example.com', 'bob@example.com', '*.py']\n" Got '' [osh-cpp status] Expected 0, got 1 stdout: stderr: argv.py @x ^~ [ stdin ]:7: fatal: Can't splice 'x' |
osh-cpp | 5 augmented assignment doesn't work on shell arrays [osh-cpp stdout] Expected "['a', 'b c']\n", got '' stdout: stderr: argv.py @x ^~ [ stdin ]:3: fatal: Can't splice 'x' |
osh-cpp | 6 Set $HOME using 'var' (i.e. Oil string var in word evaluator) [osh-cpp stdout] Expected 'foo\nfoo\n', got '\n/home/andy\n' stdout: /home/andystderr: |
osh-cpp | 7 Use shell var in Oil expression [osh-cpp stdout] Expected '3\n', got '\n' stdout: stderr: |
osh-cpp | 8 Length in two different contexts [osh-cpp stdout] Expected 'shell=5\noil=21\n', got 'shell=5\noil=\n' stdout: shell=5 oil=stderr: |
osh-cpp | 9 $[len(x)] inside strings [osh-cpp stdout] Expected '-3-\n', got '--\n' stdout: --stderr: |
osh-cpp | 10 Func with multiple args in multiple contexts [osh-cpp stdout] Expected '7 7\n', got '\n' stdout: stderr: |
osh-cpp | 11 Trailing Comma in Param list [osh-cpp stdout] Expected '7 7\n', got '\n' stdout: stderr: |
osh-cpp | 12 nested expr contexts [osh-cpp stdout] Expected 'len 3\n', got '\n' stdout: stderr: |
osh-cpp | 14 Parse { var x = 42 } [osh-cpp stdout] Expected 'x=1\n', got '' [osh-cpp status] Expected 0, got 1 stdout: stderr: echo x=$x ^~ [ stdin ]:7: fatal: Undefined variable 'x' |
osh-cpp | 15 double quoted [osh-cpp stdout] Expected '-bar-bar-default-\n', got '\n' stdout: stderr: |
osh-cpp | 16 double quoted respects strict_array [osh-cpp stdout] Expected u'', got '\n' [osh-cpp status] Expected 1, got 0 stdout: stderr: |
osh-cpp | 17 simple var sub $name $0 $1 $? etc. [osh-cpp stdout] Expected 'status=42\na b\nnamed=a\n', got 'status=\n\nnamed=\n' stdout: status= named=stderr: |
osh-cpp | 18 braced var sub ${x:-default} [osh-cpp stdout] Expected 'default\n-default-\n--default--\n', got '\n\n\n' stdout: stderr: |
osh-cpp | 19 braced var sub respects strict_array [osh-cpp stdout] Expected 'a b c\n', got '\n\n' [osh-cpp status] Expected 1, got 0 stdout: stderr: |
osh-cpp | 20 null / true / false [osh-cpp stdout] Expected 'no\nyes\nno\n', got 'no\nno\nno\n' stdout: no no nostderr: |
osh-cpp | 21 Integer literals [osh-cpp stdout] Expected '123 3 83 255\n', got '\n' stdout: stderr: |
osh-cpp | 22 Integer literals with underscores [osh-cpp stdout] Expected 'SHELL\n65536\n21\n1005\n65551\nsum 40\n', got 'SHELL\n\n\n\n\nsum\n' stdout: SHELL sumstderr: |
osh-cpp | 23 Backslash char literal (is an integer) [osh-cpp stdout] Expected '10 92 39 34\n', got ' \n' stdout: stderr: |
osh-cpp | 24 \u{3bc} is char literal [osh-cpp stdout] Expected 'yes\nmu 956\n', got '' [osh-cpp status] Expected 0, got 1 stdout: stderr: echo "mu $mu" ^~~ [ stdin ]:7: fatal: Undefined variable 'mu' |
osh-cpp | 25 Pound char literal (is an integer) [osh-cpp stdout] Expected '97 65\n', got ' \n' stdout: stderr: |
osh-cpp | 27 Float Literals [osh-cpp stdout] Expected 'less\ngreat\n', got '' stdout: stderr: |
osh | 28 Float Literals with _ (requires re2c refinement) [osh stdout] Expected 'less\ngreat\n', got '' [osh status] Expected 0, got 2 stdout: stderr: var x = 1.2 + 2_3.0e-1 # 3.5 ^~~~ [ stdin ]:2: Syntax error in expression (near Id.Expr_Float) |
osh-cpp | 28 Float Literals with _ (requires re2c refinement) [osh-cpp stdout] Expected 'less\ngreat\n', got '' [osh-cpp status] Expected 0, got 2 stdout: stderr: var x = 1.2 + 2_3.0e-1 # 3.5 ^~~~ [ stdin ]:2: Syntax error in expression (near Id.Expr_Float) |
osh-cpp | 29 Tuples [osh-cpp stdout] Expected '0\n1\n2\n', got '\n\n\n' stdout: stderr: |
osh-cpp | 30 in, not in [osh-cpp stdout] Expected 'true\nfalse\ntrue\n', got '\n\n\n' stdout: stderr: |
osh-cpp | 31 dict with 'bare word' keys [osh-cpp stdout] Expected 'len=0\nlen=1\nlen=2\n', got 'len=\nlen=\nlen=\n' stdout: len= len= len=stderr: |
osh-cpp | 32 dict with expression keys [osh-cpp stdout] Expected 'len=1\nhello\nlen=1\nbar\n', got 'len=\n\nlen=\n\n' stdout: len= len=stderr: |
osh-cpp | 33 dict literal with implicit value [osh-cpp stdout] Expected 'len=1\nfoo\nlen=2\nfoo\n', got 'len=\n\nlen=\n\n' stdout: len= len=stderr: |
osh-cpp | 34 Dict literal with string keys [osh-cpp stdout] Expected '123\n456\n', got '\n\n' stdout: stderr: |
osh-cpp | 35 Bitwise logical [osh-cpp stdout] Expected '1\n7\n6\n-8\n', got '\n\n\n\n' stdout: stderr: |
osh-cpp | 36 Shift operators [osh-cpp stdout] Expected '16\n1\n', got '\n\n' stdout: stderr: |
osh-cpp | 37 Exponentiation with ** [osh-cpp stdout] Expected '8\n', got '\nshould not get here\n' [osh-cpp status] Expected 3, got 0 stdout: should not get herestderr: |
osh-cpp | 38 Two Kinds of Division [osh-cpp stdout] Expected '2.5\n2\n', got '\n\n' stdout: stderr: |
osh-cpp | 39 mod operator [osh-cpp stdout] Expected '(Int) 2\n(Int) 1\n', got '' stdout: stderr: |
osh-cpp | 40 multiline strings, list, tuples, etc. [osh-cpp stdout] Expected 'dq=6\nsq=6\nmylist=3\nmytuple=3\n', got 'dq=\nsq=\n' [osh-cpp status] Expected 0, got 2 stdout: dq= sq=stderr: var mylist = [ ^ [ stdin ]:13: Syntax error in expression (near Id.Op_Newline) |
osh-cpp | 41 multiline dict [osh-cpp stdout] Expected 'mydict=2\n', got 'mydict=\n' stdout: mydict=stderr: |
osh-cpp | 42 multiline array and command sub (only here docs disallowed) [osh-cpp stdout] Expected 'array=3\ncomsub=6\n', got 'array=\ncomsub=\n' stdout: array= comsub=stderr: |
osh-cpp | 43 obj->method() [osh-cpp stdout] Expected 'HI\n', got '\n' stdout: stderr: |
osh-cpp | 44 obj->method does NOT give you a bound method [osh-cpp stdout] Expected u'', got '\n' [osh-cpp status] Expected 3, got 0 stdout: stderr: |
osh-cpp | 45 d.key [osh-cpp stdout] Expected 'andy\n', got '\n' stdout: stderr: |
osh-cpp | 46 a ++ b for string/list concatenation [osh-cpp stdout] Expected 'abcde\nlen=3\n', got '\nlen=\n' stdout: len=stderr: |
osh-cpp | 47 s ~~ glob and s !~~ glob [osh-cpp stdout] Expected 'yes\nno\n', got '' stdout: stderr: |
osh-cpp | 48 Type Errors [osh-cpp stdout] Expected '3\n3\n3\n3\n', got '\n\n\n\n' stdout: stderr: |
osh-cpp | 49 can't use ++ on integers [osh-cpp stdout] Expected '', got '\n' [osh-cpp status] Expected 3, got 0 stdout: stderr: |
osh-cpp | 50 can't do mystr ++ mylist [osh-cpp status] Expected 3, got 0 stdout: stderr: |