mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
test: improve a few test runner tests that time out (#15287)
This commit is contained in:
parent
aced45347b
commit
dc1d8dc3da
@ -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,
|
||||
|
@ -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);
|
||||
|
Loading…
x
Reference in New Issue
Block a user