Changeset 2163
- Timestamp:
- Mar 28, 2011, 8:35:13 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tester/scripts/test.tcl
r2142 r2163 50 50 public proc queue {op args} 51 51 52 # useful helper function -- looks for val among choices 53 public proc oneof {choices val} { 54 return [expr {[lsearch -exact $choices $val] >= 0}] 55 } 56 52 57 private common _queue ;# queue of objects waiting to run 53 58 set _queue(tests) "" ;# list of tests in the queue … … 162 167 set _runobj $result 163 168 164 if { [$_testobj get output.status] ne "ok"} {169 if {![oneof {0 ok} [$_testobj get output.status]]} { 165 170 # expected test to fail, but it didn't 166 171 set idiffs [_computeDiffs [$_toolobj xml object] $_runobj -in input] … … 183 188 } else { 184 189 set _runobj [_buildFailure $result] 185 if { [$_testobj get output.status] eq "failed"190 if {![oneof {0 ok} [$_testobj get output.status]] 186 191 && [$_testobj get output.log] eq $result} { 187 192 _setResult "Pass" … … 196 201 } else { 197 202 set _runobj [_buildFailure $result] 198 if { [$_testobj get output.status] eq "failed"203 if {![oneof {0 ok} [$_testobj get output.status]] 199 204 && [$_testobj get output.log] eq $result} { 200 205 _setResult "Pass"
Note: See TracChangeset
for help on using the changeset viewer.