diff --git a/packages/playwright/src/worker/workerMain.ts b/packages/playwright/src/worker/workerMain.ts index 3791466a21..969fb83bbc 100644 --- a/packages/playwright/src/worker/workerMain.ts +++ b/packages/playwright/src/worker/workerMain.ts @@ -541,9 +541,8 @@ export class WorkerMain extends ProcessRunner { private async _runAfterAllHooksForSuite(suite: Suite, testInfo: TestInfoImpl) { if (!this._activeSuites.has(suite)) return; - if (!process.env.NONE_ISOLATED) { + if (!process.env.NONE_ISOLATED) this._activeSuites.delete(suite); - } await this._runAllHooksForSuite(suite, testInfo, 'afterAll'); }