Skip to content
E2E Test Writer cover
TestingFree · MIT

E2E Test Writer

End-to-end tests for the flows that matter — stable selectors, self-contained data, user-visible assertions.

v1.0.0 · ~539 tokens · ⬇ 0 · Updated July 6, 2026

What it does

Writes end-to-end tests for critical user flows (auth, checkout, core action) that resist UI churn: role/label/test-id selectors not CSS, wait-for-state not sleep, self-contained idempotent data, one journey per test asserting user-visible outcomes. Reserves e2e for critical paths and keeps the suite fast enough to actually run.

Example uses

Cover the checkout flow

Checkout is your revenue path and it has no end-to-end coverage, so a regression there would be an incident.

Write a Playwright e2e test for our checkout flow: add the Starter plan to the cart, pay with Stripe's 4242 4242 4242 4242 test card, and assert the confirmation page plus the created order record. Use role and label selectors only, no fixed sleeps, and make the test create and clean up its own test user.

Test signup end to end

You just reworked onboarding and want a regression net over the signup path before the next release.

Add an e2e test for signup on our Next.js app: a new user registers with email and password, confirms the mocked verification email, and lands on the dashboard. Follow the conventions in tests/e2e/login.spec.ts and assert what the user actually sees — the redirect and the welcome heading — not internal state.

Add the declined-card test

Your happy path is covered but the most common failure case a real user hits has no test.

Our e2e suite covers the happy checkout path. Add one test for a declined payment using Stripe's 4000 0000 0000 0002 test card — assert the user sees the decline message, stays on the payment step, and that no order record gets created.

Install

# 1. Create the skill folder in your Claude setup
mkdir -p ~/.claude/skills/e2e-test-writer

# 2. Download SKILL.md into it (or move the file you just downloaded)
#    → ~/.claude/skills/e2e-test-writer/SKILL.md

# 3. Claude Code auto-discovers it on next launch.

Inside the skill

SKILL.md
---
name: e2e-test-writer
description: Write end-to-end tests for a real user flow, resilient to UI churn. Use when adding tests for a critical path (signup, checkout, core action), or when asked "write an e2e test", "test this user flow", "add a Playwright/Cypress test". Tests what the user does, stably.
---

# E2E Test Writer

Test the flows that would cost money or trust if they broke — from the user's point of
view, through the real UI. Keep them stable so they catch real regressions, not CSS tweaks.

## Pick the right flows (don't e2e everything)

E2E is slow and expensive; reserve it for critical paths: auth, checkout/payment, the core
value action, anything that would be an incident if broken. Everything else belongs in
faster unit/integration tests.

## Write for stability

- **Select by role/label/test-id**, never by CSS class or DOM position — those change with
  every restyle and make tests flaky. Prefer accessible selectors (role, label, text).
- **Wait for state, not time.** Await the element/response, never a fixed `sleep`.
- **Independent + idempotent**: each test creates its own data and cleans up; no reliance on
  a previous test or a pre-seeded account that may drift.
- **One user journey per test**, asserting the outcomes a user would notice (URL, visible
  text, a created record) — not internal state.

## Structure

```
test("<user goal>", ...):
  arrange: seed the minimal data / navigate to start
  act:     perform the real steps (fill, click, submit) as a user would
  assert:  the user-visible outcome (confirmation, redirect, new item)
  cleanup: remove created data
```

## Rules

- Test the happy path of each critical flow first; add the top 1-2 failure cases (bad
  password, declined card) second. Don't try to e2e every branch — that's unit-test work.
- If a test needs a `sleep` to pass, it's hiding a race — wait on the condition instead.
- Keep the suite fast enough that people actually run it; a 40-minute e2e suite gets skipped.

## Output

The e2e test(s) in the project's framework (read an existing one for conventions), stable
selectors, self-contained data, asserting user-visible outcomes.

Changelog

  • v1.0.02026-07-03Initial clean-room write.

Frequently asked questions

Is E2E Test Writer free?

Yes. E2E Test Writer is free to download and MIT-licensed.

Where do I install E2E Test Writer?

Place the SKILL.md file in ~/.claude/skills/e2e-test-writer/ and Claude Code auto-discovers it on next launch.

How many tokens does E2E Test Writer use?

About 539 tokens — it is designed to be token-lean.

Anthony M. — Founder & Lead Reviewer
Anthony M.Verified Builder

We're developers and SaaS builders who use these tools daily in production. Every review comes from hands-on experience building real products — DealPropFirm, ThePlanetIndicator, PropFirmsCodes, and many more. We don't just review tools — we build and ship with them every day.

Written and tested by developers who build with these tools daily.