Skip to content

Commit 17039f1

Browse files
authored
fix(webkit): fix non-mac screenshots w/ dsf (#1665)
1 parent a91304a commit 17039f1

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"playwright": {
1111
"chromium_revision": "754895",
1212
"firefox_revision": "1069",
13-
"webkit_revision": "1187"
13+
"webkit_revision": "1188"
1414
},
1515
"scripts": {
1616
"ctest": "cross-env BROWSER=chromium node test/test.js",

test/golden-utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function compareImages(actualBuffer, expectedBuffer, mimeType) {
5656
};
5757
}
5858
const diff = new PNG({width: expected.width, height: expected.height});
59-
const count = pixelmatch(expected.data, actual.data, diff.data, expected.width, expected.height, {threshold: 0.15});
59+
const count = pixelmatch(expected.data, actual.data, diff.data, expected.width, expected.height, {threshold: 0.2});
6060
return count > 0 ? { diff: PNG.sync.write(diff) } : null;
6161
}
6262

test/screenshot.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ module.exports.describe = function({testRunner, expect, product, playwright, FFO
217217
expect(screenshot).toBeInstanceOf(Buffer);
218218
}
219219
});
220-
it.fail(WEBKIT)('should work with device scale factor', async({browser, server}) => {
220+
it('should work with device scale factor', async({browser, server}) => {
221221
const context = await browser.newContext({ viewport: { width: 320, height: 480 }, deviceScaleFactor: 2 });
222222
const page = await context.newPage();
223223
await page.goto(server.PREFIX + '/grid.html');
@@ -394,7 +394,7 @@ module.exports.describe = function({testRunner, expect, product, playwright, FFO
394394
expect(screenshot).toBeGolden('screenshot-element-mobile.png');
395395
await context.close();
396396
});
397-
it.fail(WEBKIT && LINUX).skip(FFOX)('should work with device scale factor', async({browser, server}) => {
397+
it.skip(FFOX)('should work with device scale factor', async({browser, server}) => {
398398
const context = await browser.newContext({ viewport: { width: 320, height: 480 }, deviceScaleFactor: 2 });
399399
const page = await context.newPage();
400400
await page.goto(server.PREFIX + '/grid.html');

0 commit comments

Comments
 (0)