Results for dbracket.test.sh

statusoshosh_.pyosh_.cc
pass 444137
ok 222
N-I 111
FAIL 148
total484848
caseoshosh_.pyosh_.ccdescription
0pass pass pass [[ glob matching, [[ has no glob expansion
1pass pass pass [[ glob matching with escapes
2pass pass pass equality
3pass pass pass [[ glob matching with unquoted var
4pass pass pass [[ regex matching
5pass pass FAIL [[ regex syntax error
details
6pass pass pass [[ has no word splitting
7pass pass pass [[ has quote joining
8pass pass pass [[ empty string is false
9pass pass pass && chain
10pass pass pass || chain
11pass pass pass [[ compound expressions
12pass pass pass precedence of && and || inside [[
13pass pass pass precedence of && and || in a command context
14pass pass pass Octal literals with -eq
15pass pass pass Hex literals with -eq
16pass pass FAIL > on strings
details
17pass pass pass != on strings
18pass pass pass -eq on strings
19pass pass pass [[ compare with literal -f (compare with test-builtin.test.sh)
20pass pass pass [[ with op variable (compare with test-builtin.test.sh)
21pass pass pass [[ with unquoted empty var (compare with test-builtin.test.sh)
22pass FAIL FAIL [[ at runtime doesn't work
detailsdetails
23pass FAIL FAIL [[ with env prefix doesn't work
detailsdetails
24pass pass pass [[ over multiple lines is OK
25pass pass FAIL Argument that looks like a command word operator
details
26pass pass pass Argument that looks like a real operator
27pass pass FAIL User array compared to "$@" (broken unless shopt -s strict_array)
details
28pass pass pass Array coerces to string (shopt -s strict_array to disallow)
29pass pass pass (( array1 == array2 )) doesn't work
30pass pass pass Quotes don't matter in comparison
31N-I N-I N-I -eq does dynamic arithmetic parsing (not supported in OSH)
detailsdetailsdetails
32pass pass pass -eq coercion produces weird results
33pass pass pass [[ '(' ]] is treated as literal
34pass pass pass [[ '(' foo ]] is syntax error
35pass pass pass empty ! is treated as literal
36pass pass pass [[ -z ]] is syntax error
37pass pass pass [[ -z '>' ]]
38pass pass pass [[ -z '>' a ]] is syntax error
39pass pass pass test whether ']]' is empty
40pass pass pass [[ ]] is syntax error
41pass pass pass [[ && ]] is syntax error
42pass pass pass [[ a 3< b ]] doesn't work (bug regression)
43FAIL FAIL FAIL tilde expansion in [[
detailsdetailsdetails
44pass FAIL FAIL [[ ]] with redirect
detailsdetails
45pass pass pass special chars
46ok ok ok \(\) in pattern (regression)
detailsdetailsdetails
47ok ok ok extglob quoted and unquoted
detailsdetailsdetails
122 passed, 6 OK, 3 not implemented, 0 BUG, 13 failed, 0 timeouts, 0 cases skipped
1 failed under osh

Details on runs that didn't PASS

osh_.cc5 [[ regex syntax error

[osh_.cc status] Expected 2, got 1

stdout:
stderr: 
  [[ foo.py =~ * ]] && echo true
  ^~
[ stdin ]:1: fatal: Invalid regex '*': Invalid regex syntax (regex_match)
osh_.cc16 > on strings

[osh_.cc stdout] Expected u'true\nfalse\n', got ''

stdout:
stderr: 
osh_.py22 [[ at runtime doesn't work

[osh_.py status] Expected 127, got 1

stdout:
stderr: 
Error running ['[[', 'foo', '==', 'foo', ']]']: [Errno 2] No such file or directory
osh_.cc22 [[ at runtime doesn't work

[osh_.cc status] Expected 127, got 0

stdout:
(cmd_value.Argv argv:['[[' foo '==' foo ']]'] arg_spids:[3 5 7 10 12])
stderr:
Unhandled SimpleCommand
osh_.py23 [[ with env prefix doesn't work

[osh_.py status] Expected 127, got 1

stdout:
stderr: 
Error running ['[[', 'foo', '==', 'foo', ']]']: [Errno 2] No such file or directory
osh_.cc23 [[ with env prefix doesn't work

[osh_.cc status] Expected 127, got 0

stdout:
(cmd_value.Argv argv:['[[' foo '==' foo ']]'] arg_spids:[3 5 7 10 12])
stderr:
Unhandled SimpleCommand
osh_.cc25 Argument that looks like a command word operator

[osh_.cc stdout] Expected 'false\nfalse\n', got ''
[osh_.cc status] Expected 0, got -6

stdout:
stderr: 
osh_eval.dbg: cpp/osh_bool_stat.h:18: bool bool_stat::DoUnaryOp(id_kind_asdl::Id_t, Str *): Assertion `0' failed.
osh_.cc27 User array compared to "$@" (broken unless shopt -s strict_array)

[osh_.cc stdout] Expected 'true\nfalse\n', got ''
[osh_.cc status] Expected 0, got -11

stdout:
stderr: 
set 4
osh31 -eq does dynamic arithmetic parsing (not supported in OSH)

stdout:
stderr: 
osh_.py31 -eq does dynamic arithmetic parsing (not supported in OSH)

stdout:
stderr: 
osh_.cc31 -eq does dynamic arithmetic parsing (not supported in OSH)

stdout:
stderr: 
osh43 tilde expansion in [[

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

stdout:
status=1
status=1
status=1
stderr:
osh_.py43 tilde expansion in [[

[osh_.py stdout] Expected 'status=0\nstatus=0\nstatus=1\n', got 'status=1\nstatus=1\nstatus=1\n'

stdout:
status=1
status=1
status=1
stderr:
osh_.cc43 tilde expansion in [[

[osh_.cc stdout] Expected 'status=0\nstatus=0\nstatus=1\n', got 'status=1\nstatus=1\nstatus=1\n'

stdout:
status=1
status=1
status=1
stderr:
osh_.py44 [[ ]] with redirect

[osh_.py stdout] Expected '0\n--\nSTDERR\n', got ''
[osh_.py status] Expected 0, got 1
[osh_.py stderr] Found 'Traceback (most recent'

stdout:
stderr: 
Traceback (most recent call last):
  File "/home/andy/git/oilshell/oil/bin/osh_eval.py", line 417, in <module>
    status = main(sys.argv)
  File "/home/andy/git/oilshell/oil/bin/osh_eval.py", line 309, in main
    cmd_flags=cmd_eval.IsMainProgram)
  File "/home/andy/git/oilshell/oil/core/main_loop.py", line 168, in Batch
    is_return, is_fatal = cmd_ev.ExecuteAndCatch(node, cmd_flags=cmd_flags)
  File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 1461, in ExecuteAndCatch
    status = self._Execute(node)
  File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 1333, in _Execute
    status, check_errexit = self._Dispatch(node)
  File "/home/andy/git/oilshell/oil/osh/cmd_eval.py", line 638, in _Dispatch
    result = self.bool_ev.EvalB(node.expr)
  File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 895, in EvalB
    s1 = self._EvalCompoundWord(node.left)
  File "/home/andy/git/oilshell/oil/osh/sh_expr_eval.py", line 800, in _EvalCompoundWord
    val = self.word_ev.EvalWordToString(word, quote_kind=quote_kind)
  File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1498, in EvalWordToString
    self._EvalWordPart(p, part_vals, quoted=False)
  File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1332, in _EvalWordPart
    sv = self._EvalCommandSub(part.child, quoted) # type: part_value_t
  File "/home/andy/git/oilshell/oil/osh/word_eval.py", line 1959, in _EvalCommandSub
    stdout = self.shell_ex.RunCommandSub(node)
AttributeError: 'NoneType' object has no attribute 'RunCommandSub'
osh_.cc44 [[ ]] with redirect

[osh_.cc stdout] Expected '0\n--\nSTDERR\n', got "1\n--\n(cmd_value.Argv argv:[cat '/x.txt'] arg_spids:[24 26])\n"

stdout:
1
--
(cmd_value.Argv argv:[cat '/x.txt'] arg_spids:[24 26])
stderr:
Unhandled SimpleCommand
osh46 \(\) in pattern (regression)

stdout:
match1
match2
stderr:
osh_.py46 \(\) in pattern (regression)

stdout:
match1
match2
stderr:
osh_.cc46 \(\) in pattern (regression)

stdout:
match1
match2
stderr:
osh47 extglob quoted and unquoted

stdout:
lit2
pat2
stderr:
osh_.py47 extglob quoted and unquoted

stdout:
lit2
pat2
stderr:
osh_.cc47 extglob quoted and unquoted

stdout:
lit2
pat2
stderr: