Playwright
Accessibility Commands
A11y testing
4 commands
Commands
Run with visible browser
$ npx playwright test --project=chromium --headed
Run tests in specific browser with UI.
Get accessibility tree
$ await page.accessibility.snapshot()
Capture accessibility tree snapshot.
Axe accessibility tests
$ npx @axe-core/playwright test
Run automated accessibility checks.
Auto-retry flaky tests
$ npx playwright test --retries=2
Retry failed tests automatically.