Skip to content

Commit 884860b

Browse files
authored
test: unflake launcher test (#2224)
We throw an exception and then gracefully close the browser. If something went wrong, we should timeout before the test times out, kill the process and report the original exception.
1 parent 03cae92 commit 884860b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/launcher.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ describe('Playwright', function() {
5858
});
5959
it('should handle exception', async({browserType, defaultBrowserOptions}) => {
6060
const e = new Error('Dummy');
61-
const options = { ...defaultBrowserOptions, __testHookBeforeCreateBrowser: () => { throw e; } };
61+
const options = { ...defaultBrowserOptions, __testHookBeforeCreateBrowser: () => { throw e; }, timeout: 9000 };
6262
const error = await browserType.launch(options).catch(e => e);
6363
expect(error).toBe(e);
6464
});

0 commit comments

Comments
 (0)