Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit e1879b0

Browse files
author
nturgut
committed
firefox tests needs LUCI changes
1 parent 9139edf commit e1879b0

File tree

1 file changed

+17
-13
lines changed

1 file changed

+17
-13
lines changed

e2etests/web/regular_integration_tests/lib/screenshot_support.dart

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,24 @@ Future<void> runTestWithScreenshots(
5656
test.integrationDriver(
5757
driver: driver,
5858
onScreenshot: (String screenshotName, List<int> screenshotBytes) async {
59-
final Image screenshot = decodePng(screenshotBytes);
60-
final String result = compareImage(
61-
screenshot,
62-
updateGoldens,
63-
'$screenshotName-$browser.png',
64-
PixelComparison.fuzzy,
65-
diffRateFailure,
66-
forIntegrationTests: true,
67-
write: updateGoldens,
68-
);
69-
if (result != 'OK') {
70-
print('ERROR: $result');
59+
if (browser == 'chrome') {
60+
final Image screenshot = decodePng(screenshotBytes);
61+
final String result = compareImage(
62+
screenshot,
63+
updateGoldens,
64+
'$screenshotName-$browser.png',
65+
PixelComparison.fuzzy,
66+
diffRateFailure,
67+
forIntegrationTests: true,
68+
write: updateGoldens,
69+
);
70+
if (result != 'OK') {
71+
print('ERROR: $result');
72+
}
73+
return result == 'OK';
74+
} else {
75+
return true;
7176
}
72-
return result == 'OK';
7377
},
7478
);
7579
}

0 commit comments

Comments
 (0)