playwright-expert

playwright-expert is a skill for Claude Code from Aarvion-AI/stackwise-skills. It costs 156 tokens per session (2,203 once invoked), scanned A, original, MIT.

A guide for writing and fixing Playwright end-to-end tests, which check a feature through the whole application as a user would.

In plain words
What is it for?
It helps add tests for new features and bug fixes, set up authentication, isolate network calls, investigate failures with traces, configure CI test runs, and check visual changes.
Why use it?
It helps catch broken user flows and reduce flaky tests caused by fragile selectors, fixed delays, or repeated login setup.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the stackwise plugin — 15 skills shipped together

Good fit It helps add tests for new features and bug fixes, set up authentication, isolate network calls, investigate failures with traces, configure CI test runs, and check visual changes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aarvion-ai/stackwise-skills/playwright-expert
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Aarvion-AI/stackwise-skills --skill playwright-expert
Clone the repo
git clone --depth 1 https://github.com/Aarvion-AI/stackwise-skills

Made for: Claude Code.

Or install stackwise, the plugin that ships this one along with the rest of its 15 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for playwright-expert

README.md
[![agentmods](https://agentmods.dev/badge/skills/aarvion-ai/stackwise-skills/playwright-expert.svg)](https://agentmods.dev/skills/aarvion-ai/stackwise-skills/playwright-expert)
Your own site
<a href="https://agentmods.dev/skills/aarvion-ai/stackwise-skills/playwright-expert"><img src="https://agentmods.dev/badge/skills/aarvion-ai/stackwise-skills/playwright-expert.svg" alt="Measured on agentmods" height="20"></a>
Per session 156 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,203 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00156 $0.02203
Opus 5 $0.00078 $0.01102
Sonnet 5 $0.00031 $0.00441
Haiku 4.5 $0.00016 $0.00220

Measured 8d ago against content hash 0320b9214a26, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

playwright-expert scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/playwright-expert/SKILL.md · 106 lines

How it starts

The opening of the file, as written. The whole thing — 106 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Playwright Expert

Turns Claude into a senior QA engineer who treats Playwright as the merge gate: every feature or bug fix ships with an E2E test that proves it, built on web-first assertions, user-facing locators, and fixtures - never sleeps, never brittle selectors.

When to Use This Skill

  • Write or extend the E2E test that proves a just-implemented feature or bug fix works end to end
  • Convert brittle tests (CSS/XPath selectors, waitForTimeout, manual polling) to role locators and web-first assertions
  • Set up authentication with storageState so the suite logs in once per project, not once per test
  • Mock or record network traffic with page.route, route.fetch, or HAR replay to isolate the frontend
  • Diagnose and fix flaky tests using traces - treat retries as a symptom, not a fix
  • Configure parallelism, sharding, and blob-report merging for CI
  • Add visual regression checks with toHaveScreenshot and masking for dynamic content

Core Workflow

  1. Analyze - Read playwright.config.ts (projects, baseURL, webServer, storageState, reporters) and 2-3 existing specs to learn conventions: fixture files (test.extend in a fixtures.ts), POM classes, data-testid naming, auth setup project. Identify which project/spec the new coverage belongs in. Confirm the dev server the tests target actually starts (webServer block or a running instance).
  2. Specify the behavior - For a feature: the user journey that exercises it (navigate → act → observe). For a bug fix: a test that fails on the old code and passes on the fix - reproduce first, then assert the corrected behavior. One behavior per test; put shared journey steps in fixtures or POMs, not copy-paste.
  3. Implement - Role/label locators first (getByRole, getByLabel, getByTestId as escape hatch), web-first await expect(locator) assertions, zero waitForTimeout, zero networkidle. Isolate external/slow dependencies with page.route or HAR. Reuse the auth storageState; never script the login form inside the test. Load the matching reference (table below) before writing unfamiliar patterns.
  4. Verify types/lint - run npx tsc --noEmit and the project's lint command (npx eslint .); fix all reported issues and re-run until clean before proceeding.
  5. Run the new tests - npx playwright test <spec> --project=chromium; fix all failures and re-run until clean. Debug failures with the trace, not by adding waits: npx playwright test <spec> --trace on, then npx playwright show-trace (or --ui locally).
  6. Prove stability - npx playwright test <spec> --repeat-each=5 --workers=4; any failure is a race you introduced - fix the root cause (see references/flake-and-ci.md) and re-run until all repeats pass. Never "fix" this step with retries or timeouts.
  7. Gate the change - run the full affected suite (npx playwright test, or --only-changed on large suites) across configured projects; fix all reported issues and re-run until clean. Confirm the HTML report shows the new tests passing without retry annotations.

Read the full file on GitHub · 106 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 106 lines · 156 tokens per session scan A 0320b9214a26

Subscribe to this mod's changes

playwright-expert is a skill published in the GitHub repository Aarvion-AI/stackwise-skills (5 stars, last pushed 5d ago), licensed MIT. It adds 156 tokens to every session and 2,203 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

symfony:e2e-panther-playwright

Write end-to-end tests with Symfony Panther 2.4 for browser automation or Playwright for complex scenarios.

dev-toolings/superpowers-symfony · 31 tokens

chrome-verify-checks

Use when verifying a chrome-extension/ change before reporting done. The canonical 7-check list (build → Service Worker vm.createContext compat → manifest sanity → per-site content-script DOM contract → message-passing trace → test suite → manual-load checklist) + verdict rules. chrome-extension/ is a strong-guard…

jhlee0409/omni-harness-kit · 126 tokens

dogfood

Exploratory QA of web apps: find bugs, evidence, reports.

NousResearch/hermes-agent · 18 tokens

e2e-testing-patterns

Master end-to-end testing with Playwright and Cypress to build reliable test suites that catch bugs, improve confidence, and enable fast deployment. Use when implementing E2E tests, debugging flaky tests, or establishing testing standards.

wshobson/agents · 51 tokens

test-site

Tests a deployed, activated Power Pages site at runtime using browser-based navigation, page crawling, and API request verification via Playwright. Use when the user wants to test, verify, or smoke-test their deployed site.

microsoft/power-platform-skills · 46 tokens

qa

Browser-based QA verification. Launches a real browser, navigates the app, clicks buttons, fills forms, and tests user flows. Works as a standalone skill or as a phase end condition in campaigns. Requires Playwright (optional dependency, graceful skip if not installed).

SethGammon/Citadel · 56 tokens