Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
test: fix test that gave 2 pixel screenshot diff on Linux (#12671)
Andrey Lushnikov1dc581c1a0b8
diff --git a/tests/page/page-screenshot.spec.ts b/tests/page/page-screenshot.spec.tsindex 42804eb121..04acb48cf1 100644--- a/tests/page/page-screenshot.spec.ts+++ b/tests/page/page-screenshot.spec.ts@@ -728,8 +728,12 @@ it.describe('page screenshot animations', () => {page.screenshot({ fonts: 'ready' }),server.serveFile(serverRequest, serverResponse),]);- expect(iconsScreenshot).toMatchSnapshot('screenshot-web-font.png');- expect(noIconsScreenshot).not.toMatchSnapshot('screenshot-web-font.png');+ expect(iconsScreenshot).toMatchSnapshot('screenshot-web-font.png', {+ maxDiffPixels: 3,+ });+ expect(noIconsScreenshot).not.toMatchSnapshot('screenshot-web-font.png', {+ maxDiffPixels: 3,+ });});});