When to use this skill
Use this skill whenever the user wants to:
- Write or debug browser E2E tests with Playwright (multi-browser, multi-tab, auto-waiting)
- Configure projects, locators, fixtures, and CI runs
How to use this skill
- Install: npm init playwright; choose browsers and language; generate examples and configuration.
- Write: page.goto, getByRole, click, fill, expect; auto-waiting and assertions; multiple pages and API requests.
- Run: npx playwright test; headed/UI mode; reports and traces.
Best Practices
- Prefer getByRole/getByLabel; avoid fragile xpath.
- Keep tests independent and repeatable; set up state with fixtures or beforeEach.
- Install dependencies and browsers in CI; retain traces and screenshots on failure.
Keywords
playwright, E2E, end-to-end testing, multi-browser