Results for strict-options.test.sh

casedashbashmkshoshosh_ALTosh-byterundescription
0pass pass pass pass pass FAIL Sourcing a script that returns at the top level
details
1pass ok pass pass pass FAIL top level control flow
detailsdetails
2pass ok pass pass pass FAIL errexit and top-level control flow
detailsdetails
3N-I N-I N-I pass pass FAIL set -o strict-control-flow
detailsdetailsdetailsdetails
4pass ok pass pass pass FAIL return at top level is an error
detailsdetails
5pass pass pass pass pass FAIL continue at top level is NOT an error
details
6pass pass pass pass pass FAIL break at top level is NOT an error
details
7pass pass pass pass pass FAIL empty argv WITHOUT strict-argv
details
8pass pass pass FAIL FAIL FAIL strict-argv: no first word but exit code
detailsdetailsdetails
9N-I N-I N-I pass pass FAIL empty argv WITH strict-argv
detailsdetailsdetailsdetails
10N-I BUG BUG FAIL FAIL FAIL Arrays should not be incorrectly compared like bash/mksh
detailsdetailsdetailsdetailsdetailsdetails
11N-I pass pass pass pass FAIL automatically creating arrays WITHOUT strict-array
detailsdetails
12N-I pass pass pass pass FAIL automatically creating arrays are INDEXED, not associative
detailsdetails

47 passed, 3 ok, 9 known unimplemented, 2 known bugs, 2 failed, 0 skipped

Details on runs that didn't PASS

osh-byterun0 Sourcing a script that returns at the top level

[osh-byterun stdout] Expected 'one\nreturn-helper.sh\n42\ntwo\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
bash1 top level control flow

stdout:
SUBSHELL
BREAK
CONTINUE
RETURN
DONE
stderr:
spec/testdata/top-level-control-flow.sh: line 14: return: can only `return' from a function or sourced script
spec/testdata/top-level-control-flow.sh: line 17: break: only meaningful in a `for', `while', or `until' loop
spec/testdata/top-level-control-flow.sh: line 19: continue: only meaningful in a `for', `while', or `until' loop
spec/testdata/top-level-control-flow.sh: line 24: return: can only `return' from a function or sourced script
osh-byterun1 top level control flow

[osh-byterun stdout] Expected 'SUBSHELL\nBREAK\nCONTINUE\nRETURN\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
bash2 errexit and top-level control flow

stdout:
SUBSHELL
stderr:
spec/testdata/top-level-control-flow.sh: line 14: return: can only `return' from a function or sourced script
osh-byterun2 errexit and top-level control flow

[osh-byterun stdout] Expected 'SUBSHELL\n', got ''
[osh-byterun status] Expected 2, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
dash3 set -o strict-control-flow

stdout:
stderr: 
_tmp/spec-bin/dash: 0: Illegal option -o strict-control-flow
bash3 set -o strict-control-flow

stdout:
stderr: 
_tmp/spec-bin/bash: line 0: _tmp/spec-bin/bash: strict-control-flow: invalid option name
mksh3 set -o strict-control-flow

stdout:
stderr: 
_tmp/spec-bin/mksh: strict-control-flow: bad option
osh-byterun3 set -o strict-control-flow

[osh-byterun stdout] Expected 'break\n', got ''

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
bash4 return at top level is an error

stdout:
status=1
stderr:
_tmp/spec-bin/bash: line 1: return: can only `return' from a function or sourced script
osh-byterun4 return at top level is an error

[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
osh-byterun5 continue at top level is NOT an error

[osh-byterun stdout] Expected 'status=0\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
osh-byterun6 break at top level is NOT an error

[osh-byterun stdout] Expected 'status=0\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
osh-byterun7 empty argv WITHOUT strict-argv

[osh-byterun stdout] Expected 'status=0\nVarSub\nCommandSub\nVarSub FAILED\nCommandSub FAILED\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
osh8 strict-argv: no first word but exit code

[osh stdout] Expected 'FALSE\n', got 'TRUE\n'

stdout:
TRUE
stderr:
osh_ALT8 strict-argv: no first word but exit code

[osh_ALT stdout] Expected 'FALSE\n', got 'TRUE\n'

stdout:
TRUE
stderr:
osh-byterun8 strict-argv: no first word but exit code

[osh-byterun stdout] Expected 'FALSE\n', got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
dash9 empty argv WITH strict-argv

stdout:
stderr: 
_tmp/spec-bin/dash: 1: set: Illegal option -o strict-argv
bash9 empty argv WITH strict-argv

stdout:
empty
status=0
stderr:
_tmp/spec-bin/bash: line 1: set: strict-argv: invalid option name
mksh9 empty argv WITH strict-argv

stdout:
stderr: 
_tmp/spec-bin/mksh: <stdin>[1]: set: strict-argv: bad option
osh-byterun9 empty argv WITH strict-argv

[osh-byterun stdout] Expected 'empty\n', got ''

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
dash10 Arrays should not be incorrectly compared like bash/mksh

stdout:
stderr: 
_tmp/spec-bin/dash: 1: Syntax error: "(" unexpected
bash10 Arrays should not be incorrectly compared like bash/mksh

stdout:
2
4
EQUAL
stderr:
mksh10 Arrays should not be incorrectly compared like bash/mksh

stdout:
2
4
EQUAL
stderr:
osh10 Arrays should not be incorrectly compared like bash/mksh

[osh stdout] Expected '2\n4\n', got '2\n4\nEQUAL\n'
[osh status] Expected 1, got 0

stdout:
2
4
EQUAL
stderr:
osh_ALT10 Arrays should not be incorrectly compared like bash/mksh

[osh_ALT stdout] Expected '2\n4\n', got '2\n4\nEQUAL\n'
[osh_ALT status] Expected 1, got 0

stdout:
2
4
EQUAL
stderr:
osh-byterun10 Arrays should not be incorrectly compared like bash/mksh

[osh-byterun stdout] Expected '2\n4\n', got ''

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
dash11 automatically creating arrays WITHOUT strict-array

stdout:
stderr: 
_tmp/spec-bin/dash: 1: undef[2]=x: not found
_tmp/spec-bin/dash: 2: undef[3]=y: not found
_tmp/spec-bin/dash: 3: Bad substitution
osh-byterun11 automatically creating arrays WITHOUT strict-array

[osh-byterun stdout] Expected "['x', 'y']\n", got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend
dash12 automatically creating arrays are INDEXED, not associative

stdout:
stderr: 
_tmp/spec-bin/dash: 1: undef[2]=x: not found
_tmp/spec-bin/dash: 2: undef[3]=y: not found
_tmp/spec-bin/dash: 4: undef[bad]=zzz: not found
_tmp/spec-bin/dash: 5: Bad substitution
osh-byterun12 automatically creating arrays are INDEXED, not associative

[osh-byterun stdout] Expected "['zzz', 'x', 'y']\n", got ''
[osh-byterun status] Expected 0, got 1

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/opy_.py", line 10, in <module>
    from frontend import args
ImportError: No module named frontend