From dc1d8dc3da1b4572a1e48cd90db671df7d6acc0b Mon Sep 17 00:00:00 2001 From: Dmitry Gozman Date: Thu, 30 Jun 2022 17:03:01 -0700 Subject: [PATCH] test: improve a few test runner tests that time out (#15287) --- tests/playwright-test/playwright.artifacts.spec.ts | 2 ++ tests/playwright-test/playwright.spec.ts | 8 +++----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/playwright-test/playwright.artifacts.spec.ts b/tests/playwright-test/playwright.artifacts.spec.ts index 0f04f258a2..c9e1a34f01 100644 --- a/tests/playwright-test/playwright.artifacts.spec.ts +++ b/tests/playwright-test/playwright.artifacts.spec.ts @@ -122,6 +122,8 @@ const testFiles = { `, }; +test.slow(true, 'Multiple browser launches in each test'); + test('should work with screenshot: on', async ({ runInlineTest }, testInfo) => { const result = await runInlineTest({ ...testFiles, diff --git a/tests/playwright-test/playwright.spec.ts b/tests/playwright-test/playwright.spec.ts index b2489e49b6..1acf067275 100644 --- a/tests/playwright-test/playwright.spec.ts +++ b/tests/playwright-test/playwright.spec.ts @@ -67,8 +67,7 @@ test('should run in three browsers with --browser', async ({ runInlineTest }) => `, 'a.test.ts': ` const { test } = pwt; - test('pass', async ({ page, browserName }) => { - expect(page.viewportSize()).toEqual({ width: 800, height: 800 }); + test('pass', async ({ browserName }) => { console.log('\\n%%browser=' + browserName); }); `, @@ -90,8 +89,7 @@ test('should run in one browser with --browser', async ({ runInlineTest }) => { `, 'a.test.ts': ` const { test } = pwt; - test('pass', async ({ page, browserName }) => { - expect(page.viewportSize()).toEqual({ width: 800, height: 800 }); + test('pass', async ({ browserName }) => { console.log('\\n%%browser=' + browserName); }); `, @@ -406,7 +404,7 @@ test('should not report waitForEventInfo as pending', async ({ runInlineTest }, await page.click('text=Missing'); }); `, - }, { workers: 1, timeout: 2000 }); + }, { workers: 1, timeout: 5000 }); expect(result.exitCode).toBe(1); expect(result.passed).toBe(0);