write-e2e-tests

write-e2e-tests is a skill for Claude Code, Codex from systemowiec/ai-agents-workspace-starter. It costs 27 tokens per session (609 once invoked), scanned A, original, MIT.

A guide for writing end-to-end browser tests with Playwright, a tool that checks complete user journeys in a web app. It covers page objects, test data setup, assertions, and running tests in Docker.

In plain words
What is it for?
Use it to automate flows such as logging in or creating an order, update tests after UI changes, and prepare the required data and authentication state.
Why use it?
It gives tests a consistent structure and avoids unreliable setup through the user interface. This helps catch broken flows after changes to the app.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

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/systemowiec/ai-agents-workspace-starter/write-e2e-tests
Any agent
npx skills add systemowiec/ai-agents-workspace-starter --skill write-e2e-tests
Clone the repo
git clone --depth 1 https://github.com/systemowiec/ai-agents-workspace-starter

Made for: Claude Code, Codex.

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 write-e2e-tests

README.md
[![agentmods](https://agentmods.dev/badge/skills/systemowiec/ai-agents-workspace-starter/write-e2e-tests.svg)](https://agentmods.dev/skills/systemowiec/ai-agents-workspace-starter/write-e2e-tests)
Your own site
<a href="https://agentmods.dev/skills/systemowiec/ai-agents-workspace-starter/write-e2e-tests"><img src="https://agentmods.dev/badge/skills/systemowiec/ai-agents-workspace-starter/write-e2e-tests.svg" alt="Measured on agentmods" height="20"></a>
Per session 27 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 609 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.1 $0.00027 $0.00609
Opus 5 $0.00014 $0.00304
Sonnet 5 $0.00005 $0.00122
Haiku 4.5 $0.00003 $0.00061

Measured 5d ago against content hash afe6f7063716, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

write-e2e-tests 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 5d 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.

.agents/skills/write-e2e-tests/SKILL.md · 98 lines

How it starts

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

Write E2E Tests - End-to-End Tests in Playwright

Overview

Procedure for writing E2E tests in Playwright with Page Object Model. Tests run in a Docker container, data seeded via API.

When to Use

  • New feature requires E2E test coverage
  • Existing test needs updating after UI changes
  • New user flow to automate

When NOT to use:

  • Backend unit tests (use write-python-tests)
  • React component tests (use testing-library in frontend/)
  • Manual page exploration (use Playwright MCP Server)

Process

1. Identify the flow to test

Questions:

  • What user flow are we testing? (e.g. login, order creation)
  • What data is needed? (users, products, etc.)
  • Does the test require authentication?
  • What are the key assertions?

2. Create or update the Page Object

e2e/pages/{name}.page.ts

POM rules:

  • Each page/component has a separate file
  • Use getByTestId() as the primary selector
  • Methods describe user actions (not technical details)
  • Return Promise<void> or Promise<Locator>

3. Create a fixture (if needed)

e2e/fixtures/{name}.fixture.ts
  • Data seeding: via API, NOT via UI
  • Auth state: storageState, login once
  • Cleanup: remove data after test

4. Write the test

e2e/tests/{feature}/{name}.spec.ts

Test pattern: test.describe('Feature') > test('should...') > Arrange (POM + goto) > Act (actions) > Assert (expect(...).toBeVisible())

5. Run and verify

# Single test
make e2e TEST=tests/auth/login.spec.ts

# Full suite
make e2e

# Report
make e2e-report

6. Check determinism

Run the test 3 times - it must pass every time:

make e2e && make e2e && make e2e

New Test Checklist

  • Page Object created for each page in the flow
  • Selectors based on data-testid
  • Data seeded via API fixture
  • No waitForTimeout - use smart waits
  • Test independent from other tests
  • Test passes 3x in a row
  • HTML report - readable

See also

  • Role: .agents/roles/e2e-engineer.md
  • Workflow: .agents/workflows/as-e2e-engineer.md

Read the full file on GitHub · 98 lines

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. 5d ago First seen · 98 lines · 27 tokens per session scan A afe6f7063716

Subscribe to this mod's changes

write-e2e-tests is a skill published in the GitHub repository systemowiec/ai-agents-workspace-starter (2 stars, last pushed 5mo ago), licensed MIT. It adds 27 tokens to every session and 609 once invoked, about $0.0001 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

use-agent-browser-for-airi

Test AIRI display-model imports with agent-browser across stage-tamagotchi Electron, stage-web, and stage-pocket mobile web layouts. Use when uploading and verifying contributor-supplied Live2D ZIP, VRM, or MMD ZIP/PMX/PMD files through AIRI's model selector, including onboarding bypass, format-specific import…

moeru-ai/airi · 87 tokens

run-integration-tests

Build, pack, and run .NET MAUI integration tests locally. Validates templates, samples, and end-to-end scenarios using the local workload.

dotnet/maui · 35 tokens

cli-e2e-testcase-writer

Use when adding or updating Go CLI E2E coverage for one tests/clie2e/{domain} domain of the compiled lark-cli, especially when the work requires live --help or schema exploration, scenario-based clie2e.RunCmd workflows, and per-domain coverage.md maintenance.

larksuite/cli · 78 tokens

webapp-testing

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.

every-app/open-seo · 35 tokens

agent-device-evidence

Records iOS/Android native MP4 evidence for test/repro flows extracted from an Expensify GitHub PR or issue. Use when the user asks to "record the flow for PR.

Expensify/App · 43 tokens

dogfood

Systematically explore and test a mobile app on iOS/Android with agent-device to find bugs, UX issues, and other problems. Use when asked to dogfood, QA, exploratory test, find issues, bug hunt, or test this app on mobile.

callstack/agent-device · 55 tokens