Skip to content

Commit b472e84

Browse files
committed
test(check.rb): relax warning detection pattern
The new pattern detects warnings printed in non-canonical forms. Close #581.
1 parent 9f2c31f commit b472e84

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

check/check.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -691,9 +691,9 @@ def finished?
691691
# true if the FORM job put warning messages.
692692
def warning?(expected_message = nil)
693693
if expected_message.nil?
694-
@stdout =~ /(^|\R)\S+ Line \d+ --> Warning/
694+
@stdout.include?("Warning:")
695695
else
696-
@cleaned_stdout =~ Regexp.new("(^|\\R)\\S+ Line \\d+ --> Warning: .*#{Regexp.escape(expected_message)}")
696+
@cleaned_stdout =~ Regexp.new("Warning: .*#{Regexp.escape(expected_message)}")
697697
end
698698
end
699699

0 commit comments

Comments
 (0)