Skip to content
masterclass Buddy

Playwright · Function

test.afterAll

test.afterAll registers cleanup that runs once per worker after the applicable tests finish. Use it for file-level or group-level teardown.

Last updated

Since
v1.10

Syntax

test.afterAll(hookFunction)
test.afterAll(title, hookFunction)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • test.beforeAll
  • test.afterEach
  • test.beforeEach
  • test.describe

Source: Playwright Test. Checked 2026-11-03.