playwright-e2e-testing

A guide for creating and maintaining Playwright end-to-end tests, which test a complete user journey through an application.

In plain words
What is it for?
Use it to create, modify, review, or debug Playwright tests for UI workflows.
Why use it?
It separates browser actions, checks, and test scenarios, and clarifies when to explore with browser tools versus write and run test code.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/amadeusitgroup/otter/playwright-e2e-testing
Any agent
npx skills add AmadeusITGroup/otter --skill playwright-e2e-testing
Clone the repo
git clone --depth 1 https://github.com/AmadeusITGroup/otter

Made for: Claude Code, Codex.

Per session 82 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,569 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00082 $0.01569
Opus 5 $0.00041 $0.00785
Sonnet 5 $0.00016 $0.00314
Haiku 4.5 $0.00008 $0.00157

Measured 2d ago against content hash 2f7c8cde9630, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

playwright-e2e-testing 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 2d 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.

tools/llm/plugins/otter/skills/playwright-e2e-testing/SKILL.md · 152 lines

How it starts

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

Playwright E2E Testing

Standardized architecture and creation process for Playwright end-to-end tests. Enforces a three-layer separation (Actions / Checks / Scenarios), a mandatory 3-gate creation workflow, and consistent coding standards across all UI teams.

Tooling: Playwright CLI vs Playwright MCP

Use the right tool for each phase of the workflow:

Phase Tool Why
Exploring the app (understanding UI, discovering selectors, navigating flows) Playwright MCP Designed for exploratory automation — headed mode, structured accessibility snapshots in context
Writing & running tests (authoring test code, debugging failures, CI) Playwright CLI (@playwright/cli) Designed for coding agents in large codebases — lower token cost, headless, concise output

Playwright MCP — for exploration

Use Playwright MCP tools when you need to:

  • Navigate the application to understand its structure before writing tests
  • Discover available roles, labels, and test IDs on a page
  • Verify a user journey works interactively before codifying it

Playwright CLI — for test authoring

Use the CLI when you need to:

  • Verify test behavior during development (playwright-cli open <url> --headed)
  • Debug failing selectors by inspecting snapshots (playwright-cli snapshot)
  • Prototype interactions before writing test code (playwright-cli click <ref>, playwright-cli fill <ref> <text>)
  • Run tests in headless mode for validation

Architecture: Actions / Checks / Scenarios

All E2E test code follows a strict separation of concerns:

Layer Directory Contains Rules
Actions actions/<journey>-actions.ts User interactions (clicks, types, navigations) No assertions. No side effects beyond UI interaction. Reusable across scenarios.
Checks checks/<journey>-checks.ts Assertions (visibility, text, state) No interactions. Pure verification. Composable.
Scenarios scenarios/<feature>/ Composers wiring actions + checks Readable as Given-When-Then. One journey per scenario.

Read the full file on GitHub · 152 lines

Files

What ships with it

3 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. 2d ago First seen · 152 lines · 82 tokens per session scan A 2f7c8cde9630

Subscribe to this mod's changes

playwright-e2e-testing is a skill published in the GitHub repository AmadeusITGroup/otter (57 stars, last pushed 5d ago), licensed BSD-3-Clause. It adds 82 tokens to every session and 1,569 once invoked, about $0.0004 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-30.

Related

Other skills, from other repositories

vscode-visual-regression

Write Storybook stories and visual regression tests for the Kilo VS Code extension webview UI.

Kilo-Org/kilocode · 25 tokens

testing

Test Radix NG primitives across every layer and pick the RIGHT one for a change: Vitest unit (zoneless), jest-axe a11y, Playwright browser regression (apps/visual-regression), SSR (apps/radix-ssr-testing), and perf benches (apps/radix-perf-testing). Enforces the rule that layout / positioning / part-visibility /…

radix-ng/primitives · 184 tokens

add-test

Generate unit or E2E test files for existing code.

gitkraken/vscode-gitlens · 14 tokens

audit-accessibility

Unified accessibility auditing workflow across static analysis, runtime testing, ARIA patterns, keyboard navigation, and color contrast. Use this skill whenever the user mentions accessibility, a11y, WCAG, ARIA roles, axe tests, screen readers, focus management, keyboard navigation, color contrast, or wants to audit…

NVIDIA/elements · 98 tokens

eval-speckit-extension

Evaluate the speckit-extension end-to-end against a real spec — verify lifecycle hooks fired, .spec-context.json captured each step into canonical history[], timing is real (not backfilled), and per-task execution was journaled. Umbrella eval for the spec-kit-side extension; grows as features land (auto-mode, etc.).…

alfredoperez/speckit-companion · 116 tokens

e2e-testing

E2E test authoring for Backseat Driver. Use when: writing, modifying, or debugging e2e tests under e2e-test-ws/, adding new MCP test scenarios, investigating test failures, understanding test infrastructure, or working with files matching test.cljs in the e2e workspace.

BetterThanTomorrow/calva-backseat-driver · 66 tokens