Results for builtin-vars.test.sh

casedashbashmkshoshosh_ALTdescription
0pass pass pass pass pass Export sets a global variable
1N-I pass N-I pass pass Export sets a global variable that persists after export -n
detailsdetails
2N-I pass N-I pass pass export -n undefined is ignored
detailsdetails
3pass pass pass pass pass Export a global variable and unset it
4pass pass pass pass pass Export existing global variables
5pass pass pass pass pass Export existing local variable
6pass pass pass pass pass Export a local that shadows a global
7pass pass pass pass pass Export a variable before defining it
8pass pass pass pass pass Exporting a parent func variable (dynamic scope)
9pass pass pass pass pass Dependent export setting
10pass pass pass pass pass Exporting a variable doesn't change it
11ok BUG ok pass pass assign to readonly variable
detailsdetailsdetails
12ok pass ok pass pass assign to readonly variable - errexit
detailsdetails
13pass pass pass pass pass Unset a variable
14pass pass pass pass pass Unset exit status
15pass pass pass pass pass Unset nonexistent variable
16ok BUG BUG pass pass Unset readonly variable
detailsdetailsdetails
17N-I pass N-I pass pass Unset a function without -f
detailsdetails
18pass pass pass pass pass Unset has dynamic scope
19pass pass pass pass pass Unset -v
20pass pass pass pass pass Unset -f
21N-I pass pass FAIL FAIL Unset array member
detailsdetailsdetails
22N-I pass pass FAIL FAIL Unset array member with expression
detailsdetailsdetails

95 passed, 5 ok, 8 known unimplemented, 3 known bugs, 2 failed, 0 skipped

Details on runs that didn't PASS

dash1 Export sets a global variable that persists after export -n

stdout:
X
X
stderr:
/bin/dash: 5: export: Illegal option -n
mksh1 Export sets a global variable that persists after export -n

stdout:
X
X
stderr:
/bin/mksh: <stdin>[5]: export: -n: unknown option
dash2 export -n undefined is ignored

stdout:
stderr: 
/bin/dash: 2: export: Illegal option -n
mksh2 export -n undefined is ignored

stdout:
stderr: 
/bin/mksh: <stdin>[2]: export: -n: unknown option
dash11 assign to readonly variable

stdout:
stderr: 
/bin/dash: 2: foo: is read only
bash11 assign to readonly variable

stdout:
status=1
stderr:
/bin/bash: line 2: foo: readonly variable
mksh11 assign to readonly variable

stdout:
stderr: 
/bin/mksh: <stdin>[2]: read-only: foo
dash12 assign to readonly variable - errexit

stdout:
stderr: 
/bin/dash: 3: foo: is read only
mksh12 assign to readonly variable - errexit

stdout:
stderr: 
/bin/mksh: <stdin>[3]: read-only: foo
dash16 Unset readonly variable

stdout:
stderr: 
/bin/dash: 2: unset: R: is read only
bash16 Unset readonly variable

stdout:
status=1
stderr:
/bin/bash: line 2: unset: R: cannot unset: readonly variable
mksh16 Unset readonly variable

stdout:
status=1
stderr:
/bin/mksh: <stdin>[2]: read-only: R
dash17 Unset a function without -f

stdout:
foo
foo
stderr:
mksh17 Unset a function without -f

stdout:
foo
foo
stderr:
dash21 Unset array member

stdout:
stderr: 
/bin/dash: 1: Syntax error: "(" unexpected
osh21 Unset array member

[osh stdout] Expected 'x z len=2\n', got 'x y z len=3\n'

stdout:
x y z len=3
stderr:
osh_ALT21 Unset array member

[osh_ALT stdout] Expected 'x z len=2\n', got 'x y z len=3\n'

stdout:
x y z len=3
stderr:
dash22 Unset array member with expression

stdout:
stderr: 
/bin/dash: 2: Syntax error: "(" unexpected
osh22 Unset array member with expression

[osh stdout] Expected 'x z len=2\n', got 'w x y z len=4\n'

stdout:
w x y z len=4
stderr:
osh_ALT22 Unset array member with expression

[osh_ALT stdout] Expected 'x z len=2\n', got 'w x y z len=4\n'

stdout:
w x y z len=4
stderr: