Skip to content

Commit 6a50382

Browse files
committed
sta: warning checks
Signed-off-by: Øyvind Harboe <[email protected]>
1 parent 6c3b9f0 commit 6a50382

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

test/orfs/mock-array/load_power.tcl

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,19 @@ proc check_log_for_warning { logfile } {
1717
# Also list unexpected warnings here as they are found.
1818
set unexpected_warnings {}
1919
foreach line [split $log_contents "\n"] {
20-
if {[string match "*Warning:*" $line]} {
21-
if {![string match "*pin .*? not found*" $line]} {
20+
if { [string match "*Warning:*" $line] } {
21+
if { ![string match "*pin * not found*" $line] } {
2222
lappend unexpected_warnings $line
2323
}
2424
}
2525
}
26+
if { [llength $unexpected_warnings] > 0 } {
27+
puts "Error: Unexpected warnings found in log file $logfile:"
28+
foreach warning $unexpected_warnings {
29+
puts $warning
30+
}
31+
exit 1
32+
}
2633
}
2734

2835

0 commit comments

Comments
 (0)