Skip to content
Back to skills

Playwright Pro

ASecurity

Production-grade Playwright testing toolkit. Generate tests, review them, fix flaky failures, migrate from Cypress/Selenium, report results. 55 templates.

  • 3 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added November 14, 2026
testinggobashtestingdebuggingapi

Works with

  • api

Security analysis

A100/100

Pro scans all 20 files and shows the line behind each finding

Scanned November 14, 2026

npx -y skills add SebastianLuser/claude-code-arcane --skill playwright-pro --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Playwright Pro?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Playwright Pro
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/sebastianluser-playwright-pro/badge)](https://www.skillsdirectory.com/skills/sebastianluser-playwright-pro)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: playwright-pro
description: "Production-grade Playwright testing toolkit. Generate tests, review them, fix flaky failures, migrate from Cypress/Selenium, report results. 55 templates."
argument-hint: "[fix|generate|init|migrate|report|review] [args]"
category: "testing"
user-invocable: true
allowed-tools: Read, Glob, Grep, Bash, Write, Edit
---

# Playwright Pro

Production-grade Playwright testing toolkit for AI coding agents.

> **Note:** This skill may create or modify files in your project. It will ask before writing.

## Sub-commands

`/playwright-pro` with no argument shows this overview. With a sub-command as its first argument, read `skills/<sub-command>/SKILL.md` from this skill's directory and follow it, passing the remaining arguments. Sub-commands: `fix`, `generate`, `init`, `migrate`, `report`, `review`.

## Quick Start Workflow

The recommended sequence for most projects:

```
1. /playwright-pro init          -> scaffolds config, CI pipeline, and a first smoke test
2. /playwright-pro generate      -> generates tests from your spec or URL
3. /playwright-pro review        -> validates quality and flags anti-patterns      <- always run after generate
4. /playwright-pro fix <test>    -> diagnoses and repairs any failing/flaky tests  <- run when CI turns red
```

**Validation checkpoints:**
- After `/playwright-pro generate` -- always run `/playwright-pro review` before committing
- After `/playwright-pro fix` -- re-run the full suite locally (`npx playwright test`)
- After `/playwright-pro migrate` -- run both suites and compare test counts and results before decommissioning old tests

## Golden Rules

1. `getByRole()` over CSS/XPath -- resilient to markup changes
2. Never `page.waitForTimeout()` -- use web-first assertions
3. `expect(locator)` auto-retries; `expect(await locator.textContent())` does not
4. Isolate every test -- no shared state between tests
5. `baseURL` in config -- zero hardcoded URLs
6. Retries: `2` in CI, `0` locally
7. Traces: `'on-first-retry'` -- rich debugging without slowdown
8. Fixtures over globals -- `test.extend()` for shared state
9. One behavior per test -- multiple related assertions are fine
10. Mock external services only -- never mock your own app

## Locator Priority

```
1. getByRole()        -- buttons, links, headings, form elements
2. getByLabel()       -- form fields with labels
3. getByText()        -- non-interactive text
4. getByPlaceholder() -- inputs with placeholder
5. getByTestId()      -- when no semantic option exists
6. page.locator()     -- CSS/XPath as last resort
```

## What's Included

- **6 sub-commands** with detailed step-by-step instructions
- **55 test templates**: auth, CRUD, checkout, search, forms, dashboard, settings, onboarding, notifications, API, accessibility
- **6 reference docs**: golden rules, locators, assertions, fixtures, pitfalls, flaky tests
- **Migration guides**: Cypress and Selenium mapping tables

## Quick Reference

See `references/` directory for:
- `golden-rules.md` -- The 10 non-negotiable rules
- `locators.md` -- Complete locator priority with cheat sheet
- `assertions.md` -- Web-first assertions reference
- `fixtures.md` -- Custom fixtures and storageState patterns
- `common-pitfalls.md` -- Top 10 mistakes and fixes
- `flaky-tests.md` -- Diagnosis commands and quick fixes

See `templates/README.md` for the full template index.

Files in this skill

  • LICENSE1 KB
  • SKILL.md3.3 KB
  • references/assertions.md2.2 KB
  • references/common-pitfalls.md3.1 KB
  • references/fixtures.md3.1 KB
  • references/flaky-tests.md1.5 KB
  • references/golden-rules.md906 B
  • references/locators.md2.1 KB
  • skills/fix/SKILL.md3 KB
  • skills/fix/flaky-taxonomy.md3.4 KB
  • skills/generate/SKILL.md4.5 KB
  • skills/generate/patterns.md5.7 KB
  • skills/init/SKILL.md4.1 KB
  • skills/migrate/SKILL.md4.2 KB
  • skills/migrate/cypress-mapping.md3.6 KB
  • skills/migrate/selenium-mapping.md4.4 KB
  • skills/report/SKILL.md2.7 KB
  • skills/review/SKILL.md3 KB
  • skills/review/anti-patterns.md4.2 KB
  • templates/README.md4.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.