const test = defaultTest.extend({
audit: async ({ page }) => {
await page.screenshot({ path: 'e2e/test.png' });
console.info('audit done!');
},
});
// ...more code
test.only('audit', async ({ page, mount, audit }) => {
await audit(page);
// ...test code
}));
Error:
Running 1 test using 1 worker
✘ 1 [chromium] ›audit.playwright.tsx:48:6 › audit (10.0s)
audit done!
1) [chromium] › audit.playwright.tsx:48:6 › audit ─────────────────────────────────────
Test timeout of 10000ms exceeded while setting up "audit".
1 failed
[chromium] › audit.playwright.tsx:48:6 › audit
Simple query. I need a screenshot taken during the audit, followed by the test's continuation. A screenshot file is generated successfully, but the test then times out. Removing the fixture from the test allows the test to function as intended. What could be missing here?