Results for builtin-bracket.test.sh

statusdashbashmkshosh
pass 42494552
ok 4230
N-I 5010
BUG 1130
total52525252
casedashbashmkshoshdescription
0pass pass pass pass zero args: [ ]
1pass pass pass pass one arg: [ x ] where x is one of '=' '!' '(' ']'
2pass pass pass pass one arg: empty string is false. Equivalent to -n.
3N-I pass pass pass -a as unary operator (alias of -e)
details
4pass pass pass pass two args: -z with = ! ( ]
5pass pass pass pass three args
6pass pass pass pass four args
7pass pass pass pass test with extra args is syntax error
8pass pass pass pass ] syntax errors
9pass pass pass pass -n
10pass pass pass pass ! -a
11pass pass pass pass -o
12pass pass pass pass ( )
13pass pass pass pass ( ) ! -a -o with system version of [
14BUG pass pass pass == is alias for =
details
15N-I pass pass pass == and = does not do glob
details
16pass pass pass pass [ with op variable
17pass pass pass pass [ with unquoted empty var
18pass pass pass pass [ compare with literal -f
19pass pass pass pass [ '(' foo ] is runtime syntax error
20pass pass pass pass -z '>' implies two token lookahead
21ok pass ok pass operator/operand ambiguity with ]
detailsdetails
22ok pass ok pass operator/operand ambiguity with -a
detailsdetails
23pass pass pass pass -d
24pass pass pass pass -x
25pass pass pass pass -r
26pass pass pass pass -w
27pass pass pass pass -k for sticky bit
28pass pass pass pass -h and -L test for symlink
29pass pass pass pass -t 1 for stdout
30pass BUG pass pass [ -t invalid ]
details
31pass pass pass pass -ot and -nt
32pass pass BUG pass [ a -eq b ]
details
33pass pass pass pass test -s
34pass pass pass pass test -b -c -S (block, character, socket)
35pass pass pass pass test -p named pipe
36pass pass pass pass -G and -O for effective user ID and group ID
37pass pass pass pass -u for setuid, -g too
38N-I pass N-I pass -v to test variable (bash)
detailsdetails
39N-I pass pass pass test -o for options
details
40pass pass pass pass -nt -ot
41pass pass pass pass -ef
42ok ok pass pass Overflow error
detailsdetails
43pass pass pass pass Bug regression
44pass pass pass pass test -c
45pass pass pass pass test -S
46pass pass pass pass bug from pnut: negative number $((-1))
47pass pass pass pass negative octal numbers, etc.
48N-I pass pass pass More negative numbers
details
49pass pass BUG pass No octal, hex, base N conversion - leading 0 is a regular decimal
details
50ok ok ok pass Looks like octal, but digit is too big
detailsdetailsdetails
51pass pass BUG pass no recursive arith [ 1+2 -eq 3 ]
details
188 passed, 9 OK, 6 not implemented, 5 BUG, 0 failed, 0 timeouts, 0 cases skipped

Details on runs that didn't PASS

dash3 -a as unary operator (alias of -e)

stdout:
status=2
status=2
stderr:
dash: 1: [: -a: unexpected operator
dash: 3: [: -a: unexpected operator
dash14 == is alias for =

stdout:
true
stderr:
dash: 2: [: a: unexpected operator
dash15 == and = does not do glob

stdout:
status=1
status=2
stderr:
dash: 3: [: abc: unexpected operator
dash21 operator/operand ambiguity with ]

stdout:
status=2
stderr:
dash: 1: [: -a: unexpected operator
mksh21 operator/operand ambiguity with ]

stdout:
status=2
stderr:
mksh: <stdin>[1]: [: ]: unexpected operator/operand
dash22 operator/operand ambiguity with -a

stdout:
status=1
stderr:
mksh22 operator/operand ambiguity with -a

stdout:
status=2
stderr:
mksh: <stdin>[1]: [: expression expected
bash30 [ -t invalid ]

stdout:
status=1
stderr:
mksh32 [ a -eq b ]

stdout:
status=0
stderr:
dash38 -v to test variable (bash)

stdout:
global=2
global=2
dynamic=2
dynamic=2
dynamic=2
stderr:
dash: 1: test: -v: unexpected operator
dash: 5: test: -v: unexpected operator
dash: 14: test: -v: unexpected operator
dash: 16: test: -v: unexpected operator
dash: 18: test: -v: unexpected operator
mksh38 -v to test variable (bash)

stdout:
global=2
global=2
dynamic=2
dynamic=2
dynamic=2
stderr:
mksh: <stdin>[1]: test: nonexistent: unexpected operator/operand
mksh: <stdin>[5]: test: g: unexpected operator/operand
mksh: <stdin>[21]: test: f_var: unexpected operator/operand
mksh: <stdin>[21]: test: g: unexpected operator/operand
mksh: <stdin>[21]: test: nonexistent: unexpected operator/operand
dash39 test -o for options

stdout:
status=2
status=2
status=2
stderr:
dash: 1: test: -o: unexpected operator
dash: 5: test: -o: unexpected operator
dash: 8: test: -o: unexpected operator
dash42 Overflow error

stdout:
status=1
stderr:
bash42 Overflow error

stdout:
status=1
stderr:
dash48 More negative numbers

stdout:
stderr: 
mksh49 No octal, hex, base N conversion - leading 0 is a regular decimal

stdout:
73
-73

status=0
status=0

hex=2
baseN=2
stderr:
mksh: <stdin>[14]: 0xff: bad number '0xff'
mksh: <stdin>[16]: 64#a: bad number '64#a'
dash50 Looks like octal, but digit is too big

stdout:
stderr: 
dash: 1: arithmetic expression: expecting EOF: " 083 "
bash50 Looks like octal, but digit is too big

stdout:
status=1
status=1

status=0
status=0
stderr:
bash: line 1: 083: value too great for base (error token is "083")
bash: line 4: -083: value too great for base (error token is "083")
mksh50 Looks like octal, but digit is too big

stdout:
83
status=0
-83
status=0

status=0
status=0
stderr:
mksh51 no recursive arith [ 1+2 -eq 3 ]

stdout:
status=0
status=0
stderr: