Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

feat(test runner): disable test timeout on page.pause() call (#10944)

Dmitry Gozman19b08332cec7
diff --git a/packages/playwright-test/src/index.ts b/packages/playwright-test/src/index.ts
index 86ca60ad35..e66c148090 100644
--- a/packages/playwright-test/src/index.ts
+++ b/packages/playwright-test/src/index.ts
@@ -207,6 +207,8 @@ export const test = _baseTest.extend<TestFixtures, WorkerFixtures>({
onApiCallBegin: (apiCall: string, stackTrace: ParsedStackTrace | null, userData: any) => {
if (apiCall.startsWith('expect.'))
return { userObject: null };
+ if (apiCall === 'page.pause')
+ testInfo.setTimeout(0);
const testInfoImpl = testInfo as any;
const step = testInfoImpl._addStep({
location: stackTrace?.frames[0],