write-e2e

Generate Playwright E2E tests from codebase route and flow analysis.

6|Updated Mar 27, 2026
One-click install
npx skills add https://github.com/greglas75/zuvo --skill write-e2e-greglas75
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: write-e2e
Source: https://github.com/greglas75/zuvo/tree/main/skills/write-e2e
Command: npx skills add https://github.com/greglas75/zuvo --skill write-e2e-greglas75

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing meaningful end-to-end tests requires discovering routes, ranking user flows by risk, and asserting real causality rather than incidental page state. This Skill automates that pipeline: it analyzes a web application's codebase, scores user flows by criticality, generates Playwright specs that assert observable outcomes, and honestly reports what was actually proven versus merely written. ## Core Features & Use Cases - Route and flow discovery with criticality scoring: Scans routes, forms, API endpoints, and auth patterns, then scores each candidate flow on five weighted signals (mutation, auth, sensitivity, traffic, coverage) with confidence labels. - Causality-first spec generation: Every scenario fills a causality contract (trigger, decisive event, pre-state, post-state, visible oracle, cleanup) before any spec code is written, enforced by ten critical quality gates E2E-Q1 through E2E-Q10. - Verification ladder with honest states: Each flow earns exactly one state — GENERATED, STATIC_CHECKED, VERIFIED_LOCAL, VALIDATED_LIVE, BLOCKED, or FAILED — so unexecuted specs are never reported as passing coverage. - Origin safety and consent gates: Classifies every target as LOCAL, STAGING, or EXTERNAL_UNKNOWN with fail-closed network mocking, blocking mutations against non-local origins without explicit consent flags. - Use Case: Point it at a Next.js app with --auto to generate the three highest-scored Playwright specs, execute them locally, and receive a coverage registry showing exactly which flows were verified. ## Quick Start Ask the AI to generate Playwright E2E tests for the most critical user flows in this project and run them locally.

Frequently Asked Questions about write-e2e

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Playwright E2E tests automatically from my codebase?

Run the skill with a scope or --auto flag to discover routes, score user flows by criticality, and generate .spec.ts files. Use --flows to preview the ranked list without writing anything, or --dry-run to see the full scaffold plan first.

How are E2E test flows prioritized for generation?

Each candidate flow is scored 0-100 on five weighted signals: mutation type (30), auth requirement (20), data sensitivity (20), user traffic (15), and existing coverage (15). Flows scoring 70+ are CRITICAL and generated first; bare --auto takes the top three.

Can generated Playwright tests run against staging or production?

Only with explicit consent. Non-local origins require --allow-external-origin for read-only execution, and mutating operations additionally need --allow-destructive naming the exact operations. Unclassified origins are treated as EXTERNAL_UNKNOWN and mutations are blocked.

What happens if Playwright is not installed in the project?

The preflight probe reports BOOTSTRAP_REQUIRED when Playwright is declared but not materialized, and the skill installs the project's pinned dependencies using lockfile-respecting modes. With --no-install or a failed install, the run caps at STATIC_CHECKED with a WARN verdict.

Why do generated tests avoid waitForTimeout and networkidle?

Fixed sleeps and networkidle are banned by gate E2E-Q1 because they pass locally but flake on loaded CI runners. Specs instead use web-first assertions on the post-state or waits tied to the specific response the action triggers.

What is the difference between GENERATED and VERIFIED_LOCAL test states?

GENERATED means the spec file was written but nothing executed; VERIFIED_LOCAL means it ran green with playwright test against a local origin. A spec that was never executed is always recorded as GENERATED regardless of confidence.