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: gardening some tests failing on WebKit (#39439)
Yury Semikhatskye54aeb1d9106
diff --git a/tests/library/browsercontext-timezone-id.spec.ts b/tests/library/browsercontext-timezone-id.spec.tsindex 9a2e596a2c..5c4229d281 100644--- a/tests/library/browsercontext-timezone-id.spec.ts+++ b/tests/library/browsercontext-timezone-id.spec.ts@@ -24,25 +24,25 @@ it('should work @smoke', async ({ browser, browserName }) => {{const context = await browser.newContext({ locale: 'en-US', timezoneId: 'America/Jamaica' });const page = await context.newPage();- expect(await page.evaluate(func)).toContain('Sat Nov 19 2016 13:12:34 GMT-0500');+ expect.soft(await page.evaluate(func)).toContain('Sat Nov 19 2016 13:12:34 GMT-0500');await context.close();}{const context = await browser.newContext({ locale: 'en-US', timezoneId: 'Pacific/Honolulu' });const page = await context.newPage();- expect(await page.evaluate(func)).toContain('Sat Nov 19 2016 08:12:34 GMT-1000');+ expect.soft(await page.evaluate(func)).toContain('Sat Nov 19 2016 08:12:34 GMT-1000');await context.close();}{const context = await browser.newContext({ locale: 'en-US', timezoneId: browserName === 'firefox' ? 'America/Argentina/Buenos_Aires' : 'America/Buenos_Aires' });const page = await context.newPage();- expect(await page.evaluate(func)).toContain('Sat Nov 19 2016 15:12:34 GMT-0300');+ expect.soft(await page.evaluate(func)).toContain('Sat Nov 19 2016 15:12:34 GMT-0300');await context.close();}{const context = await browser.newContext({ locale: 'en-US', timezoneId: 'Europe/Berlin' });const page = await context.newPage();- expect(await page.evaluate(func)).toContain('Sat Nov 19 2016 19:12:34 GMT+0100');+ expect.soft(await page.evaluate(func)).toContain('Sat Nov 19 2016 19:12:34 GMT+0100');await context.close();}});diff --git a/tests/library/browsertype-connect.spec.ts b/tests/library/browsertype-connect.spec.tsindex 42c34120de..a295198bd3 100644--- a/tests/library/browsertype-connect.spec.ts+++ b/tests/library/browsertype-connect.spec.ts@@ -247,7 +247,9 @@ for (const kind of ['launchServer', 'run-server'] as const) {expect(request.headers['foo']).toBe('bar');});- test('should send default User-Agent and X-Playwright-Browser headers with connect request', async ({ connect, browserName, server }) => {+ test('should send default User-Agent and X-Playwright-Browser headers with connect request', async ({ connect, browserName, server, isMac, macVersion }) => {+ test.skip(browserName === 'webkit' && isMac && macVersion <= 14, 'WebKit on macOS-14 is frozen');+const [request] = await Promise.all([server.waitForWebSocketConnectionRequest(),connect(`ws://localhost:${server.PORT}/ws`, {diff --git a/tests/library/popup.spec.ts b/tests/library/popup.spec.tsindex f4774a7567..584f4505ab 100644--- a/tests/library/popup.spec.ts+++ b/tests/library/popup.spec.ts@@ -17,7 +17,9 @@import { browserTest as it, expect } from '../config/browserTest';import type { Page } from 'playwright-core';-it('should inherit user agent from browser context @smoke', async function({ browser, server }) {+it('should inherit user agent from browser context @smoke', async function({ browser, server, browserName, isMac, macVersion }) {+ it.skip(browserName === 'webkit' && isMac && macVersion <= 14, 'WebKit on macOS-14 is frozen');+const context = await browser.newContext({userAgent: 'hey'});