Results for xtrace.test.sh

statusbashdashmkshosh
pass 105713
ok 6683
N-I 0510
BUG 1110
FAIL 0001
total17171717
casebashdashmkshoshdescription
0pass pass pass pass unset PS4
1ok pass pass FAIL set -o verbose prints unevaluated code
detailsdetails
2ok N-I BUG pass xtrace with unprintable chars
detailsdetailsdetails
3pass N-I pass pass xtrace with unicode chars
details
4pass pass pass pass xtrace with paths
5BUG N-I pass pass xtrace with tabs
detailsdetails
6ok BUG ok pass xtrace with whitespace, quotes, and backslash
detailsdetailsdetails
7ok N-I pass pass xtrace with newlines
detailsdetails
8pass pass ok pass xtrace written before command executes
details
9ok ok ok pass Assignments and assign builtins
detailsdetailsdetails
10ok N-I N-I pass [[ ]]
detailsdetailsdetails
11pass ok ok ok PS4 is scoped
detailsdetailsdetails
12pass ok ok ok xtrace with variables in PS4
detailsdetailsdetails
13pass ok ok pass PS4 with unterminated ${
detailsdetails
14pass ok ok pass PS4 with unterminated $(
detailsdetails
15pass ok ok pass PS4 with runtime error
detailsdetails
16pass pass pass ok Reading $? in PS4
details
35 passed, 23 OK, 6 not implemented, 3 BUG, 1 failed, 0 timeouts, 0 cases skipped
1 failed under osh

Details on runs that didn't PASS

bash1 set -o verbose prints unevaluated code

stdout:
foo
bar
stderr:
x=foo
y=bar
echo $x
echo $(echo $y)
osh1 set -o verbose prints unevaluated code

[osh stderr] Expected 'x=foo\ny=bar\necho $x\necho $(echo $y)\n', got 'Warning: set -o verbose not implemented\n'

stdout:
foo
bar
stderr:
Warning: set -o verbose not implemented
bash2 xtrace with unprintable chars

stdout:
abc
stderr:
+ echo $'a\003b\004c'
dash2 xtrace with unprintable chars

stdout:
stderr: 
mksh2 xtrace with unprintable chars

stdout:
a;c
stderr:
+ echo $'a;\004c\r'
dash3 xtrace with unicode chars

stdout:
stderr: 
bash5 xtrace with tabs

stdout:
[	]
stderr:
+ echo '[	]'
dash5 xtrace with tabs

stdout:
stderr: 
bash6 xtrace with whitespace, quotes, and backslash

stdout:
1 2 ' " \
stderr:
+ echo '1 2' \' '"' '\'
dash6 xtrace with whitespace, quotes, and backslash

stdout:
1 2 ' " \
stderr:
+ echo 1 2 ' " \
mksh6 xtrace with whitespace, quotes, and backslash

stdout:
1 2 ' " \
stderr:
+ echo '1 2' \' '"' '\'
bash7 xtrace with newlines

stdout:
[
]
stderr:
+ echo '[
]'
dash7 xtrace with newlines

stdout:
$[
]
stderr:
+ echo $[\n]
mksh8 xtrace written before command executes

stdout:
stderr: 
+ >&2 
+ echo one
one
+ >&2 
+ echo two
two
bash9 Assignments and assign builtins

stdout:
2
stderr:
+ x=1
+ x=2
+ echo 2
+ readonly x=3
+ x=3
dash9 Assignments and assign builtins

stdout:
2
stderr:
+ x=1 x=2
+ echo 2
+ readonly x=3
mksh9 Assignments and assign builtins

stdout:
2
stderr:
+ x=1 x=2 
+ echo 2
+ readonly 'x=3'
bash10 [[ ]]

stdout:
stderr: 
+ dir=/
+ [[ -d / ]]
+ ((  a = 42  ))
dash10 [[ ]]

stdout:
stderr: 
mksh10 [[ ]]

stdout:
stderr: 
dash11 PS4 is scoped

stdout:
one
func
two
stderr:
+ echo one
+ f
+ local PS4=- 
- echo func
+ echo two
mksh11 PS4 is scoped

stdout:
one
func
two
stderr:
+ echo one
+ f
+ typeset 'PS4=- '
- echo func
+ echo two
osh11 PS4 is scoped

stdout:
one
func
two
stderr:
+ echo one
+ f
+ local PS4='- '
- echo func
+ echo two
dash12 xtrace with variables in PS4

stdout:
one
two
stderr:
+1:x=1
+1:echo one
+2:x=2
+2:echo two
mksh12 xtrace with variables in PS4

stdout:
one
two
stderr:
+:x=1 
+1:echo one
+1:x=2 
+2:echo two
osh12 xtrace with variables in PS4

stdout:
one
two
stderr:
+1:x=1
+1:echo one
+2:x=2
+2:echo two
dash13 PS4 with unterminated ${

stdout:
stderr: 
dash: 1: Syntax error: Missing '}'
mksh13 PS4 with unterminated ${

stdout:
stderr: 
mksh: no closing quote
dash14 PS4 with unterminated $(

stdout:
stderr: 
dash: 1: Syntax error: end of file unexpected (expecting ")")
mksh14 PS4 with unterminated $(

stdout:
stderr: 
mksh: syntax error: '(' unmatched
dash15 PS4 with runtime error

stdout:
stderr: 
dash: 4: arithmetic expression: division by zero: " 1 / 0 "
mksh15 PS4 with runtime error

stdout:
stderr: 
mksh: <stdin>[4]:  1 / 0 : zero divisor
osh16 Reading $? in PS4

stdout:
ok
stderr:
[last=0] 'false'
[last=1] echo ok