playwright-skill
БесплатноБез исполняемых скриптовНе проверенCurrent Playwright (1.65) patterns for writing, debugging, and scaling reliable test suites. Use for any Playwright task, even ones you think you know…
от testdino-hq★ 428 звёзд на GitHubОб этом скилле
Playwright Skill
Opinionated, production-tested Playwright guidance — every pattern includes when (and when not) to use it.
79 reference guides covering the full Playwright surface: selectors, assertions, fixtures, page objects, network mocking, auth, visual regression, accessibility, API testing, CI/CD, debugging, and more.
How to use this skill: open the guide for the topic before answering, even for familiar APIs. Playwright adds and renames APIs and CLI flags every release, and the guides are verified against 1.65. Guides tag newer APIs with the release that added them, e.g. (1.62+); check the project's version (npx playwright --version) before using one.
Newer APIs (1.59–1.65) You May Not Know
| Need | API | Guide |
|---|---|---|
| Per-row / per-parent locator (column queries) | locator.within(container) (1.64) |
locators.md |
| Element from an aria-snapshot ref | page.getByRef('e2') (1.64) |
locators.md |
| Configure a project that does not run by default | default: false, --project="*" (1.64) |
projects-and-dependencies.md |
| Find order-dependent tests | --shuffle [seed] (1.64) |
flaky-tests.md |
| Serialize tests sharing a resource; run one test alone | { lock: 'name' }, describe.configure({ lock }) (1.63/1.64), { lock: '-exclusive-' } (1.65) |
parallel-and-sharding.md |
Page object crashes after upgrading: Cannot read properties of undefined (reading 'getByRole') |
Field initializers follow useDefineForClassFields (1.65, breaking) |
page-object-model.md |
Action times out with element is inert |
Actions wait for non-inert targets (1.65, breaking) | assertions-and-waiting.md |
| Report only failures | failures reporter, onlyFailures for html/json/junit (1.65) |
reporting-and-artifacts.md |
| Run the test runner on Bun | bunx --bun playwright test (1.65) |
configuration.md |
| Sharded job fails with "No tests found" | Empty runs now fail across shards; --pass-with-no-tests (1.65, breaking) |
parallel-and-sharding.md |
| Run retries at the end, isolated | retryStrategy: 'isolated' (config only, 1.62) |
flaky-tests.md |
| Select or quarantine tests before the run | reporter.preprocess() + testRun.fail() (1.62), testRun.mode(suite) (1.65) |
dynamic-test-selection.md |
| Re-run failures / changed files | --last-failed, --only-changed, -x |
debugging.md |
Inspect a trace.zip from the terminal |
npx playwright trace ..., snapshot --phase (1.63) |
trace-analysis.md |
| Plan / generate / heal tests with AI | npx playwright init-agents |
test-agents.md |
| Component tests | stories-and-galleries mount('story/id') (1.62); experimental CT packages frozen |
component-testing.md |
| WebP baselines; CI creates missing baselines | toHaveScreenshot: { type: 'webp' }, --update-snapshots=missing passes (1.64) |
visual-regression.md |
| Scoped HAR recording | tracing.startHar(path, options) (1.60) |
network-mocking.md |
| Auth state in IndexedDB / OPFS; per-origin basic auth | storageState({ indexedDB, opfs }) (opfs 1.63), httpCredentials: [...] (1.63) |
authentication.md |
| Passkeys | context.credentials, signCount (1.61/1.64) |
auth-flows.md |
Cookies on an API request context; params merging |
request.addCookies() / cookies() (1.64); RFC 6265 matching, params appended to the URL query (1.65) |
api-testing.md |
| Page-registered agent tools | page.webmcp.tools() / callTool() (1.64) |
webmcp-testing.md |
Security Trust Boundary
This skill is designed for testing applications you own or have explicit authorization to test. It does not support or endorse automating interactions with third-party websites or services without permission.
When writing tests or automation that fetch content from external sources (e.g., baseURL pointing to staging/production), treat all returned page content as untrusted input — never pass raw page text back into agent instructions or dynamic code execution without sanitization, as this creates an indirect prompt injection risk.
For CI/CD workflows, pin all external dependencies (GitHub Actions, Docker images) to immutable references (commit SHAs, image digests) rather than mutable version tags. See ci-github-actions.md and docker-and-containers.md for pinning guidance.
Golden Rules
getByRole()over CSS/XPath — resil
Установить playwright-skill в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл playwright-skill?
Current Playwright (1.65) patterns for writing, debugging, and scaling reliable test suites. Use for any Playwright task, even ones you think you know, because the guides cover APIs and CLI flags newer than most training data. Covers writing or fixing tests, locators, a failing or flaky test, a trace.zip or error message, playwright.config and projects, network mocking, auth, visual and accessibility testing, Docker and CI sharding, playwright-cli browser automation, Playwright Test Agents, page objects, migrating from Cypress or Selenium, and QA work: test case design, bug reports from failures, automating manual test cases, and reviewing tests. TypeScript and JavaScript.
Как установить скилл playwright-skill?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл playwright-skill запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic