mirror of
https://github.com/zebrajr/ladybird.git
synced 2025-12-06 00:19:53 +01:00
Tests: Report image differences on tests with no fuzzy config defined
This can be helpful for identifying what the fuzzy config should be for new tests.
This commit is contained in:
parent
90b49b9015
commit
75046857ce
|
|
@ -27,8 +27,10 @@ bool fuzzy_screenshot_match(URL::URL const& reference, Gfx::Bitmap const& bitmap
|
|||
return fuzzy_match.reference.value().equals(reference);
|
||||
return true;
|
||||
});
|
||||
if (!fuzzy_match.has_value())
|
||||
return diff.identical;
|
||||
if (!fuzzy_match.has_value()) {
|
||||
warnln("Screenshot mismatch: pixel error count {}, with maximum error {}. (No fuzzy config defined)", diff.pixel_error_count, diff.maximum_error);
|
||||
return false;
|
||||
}
|
||||
|
||||
// Apply fuzzy matching.
|
||||
auto color_error_matches = fuzzy_match->color_value_error.contains(diff.maximum_error);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user