agentleFS
ella79ella79/agentic-playwright-suite/CLAUDE.md

agentic-playwright-suite

CLAUDE.md8 starsChanged 2 months agoMITView on GitHub

End to end, API and visual regression test suite for Automation Exercise, built with Playwright and TypeScript. Yarn 4 through Corepack; there is no global install. Invoke everything with yarn. Browser interaction during development goes through the two MCP servers in .mcp.json (playwright-test for authoring, playwright for exploration), not a direct yarn playwright <args> invocation; see .claude/skills/playwright-mcp/SKILL.md. The full list, with the headed, UI, debug and report variants, is in docs/architecture.md. Base URL defaults to https://automationexercise.com. Override with E2E_BASE_URL. The…

The file

We split this CLAUDE.md into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Start with playwright-test-manager for any session or coverage question: it owns the cycle and delegates to the four specialists.

    line 65

≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

Agentic Playwright Suite

End to end, API and visual regression test suite for Automation Exercise, built with Playwright and TypeScript.

Tech Stack

  • Node.js 20+ + Yarn 4 via Corepack (yarn.lock is the only lockfile; CI runs yarn install --immutable)
  • TypeScript 5: strict mode
  • Playwright: Chromium and WebKit for the functional suite, Chromium only for visual regression, fully parallel runs
  • Allure: reporting, published to GitHub Pages with trend history

Environment

Yarn 4 through Corepack; there is no global install. Invoke everything with yarn. Browser interaction during development goes through the two MCP servers in .mcp.json (playwright-test for authoring, playwright for exploration), not a direct yarn playwright <args> invocation; see .claude/skills/playwright-mcp/SKILL.md.

Commands

CommandPurpose
yarn test:e2eRun all functional E2E tests
yarn test:apiRun all API tests
yarn test:vrRun all visual regression tests
yarn docker:vr / yarn docker:vr:updateRun or regenerate baselines in the image CI uses
yarn typecheck, yarn lint, yarn stylecheckThe three static checks. All must be clean

The full list, with the headed, UI, debug and report variants, is in docs/architecture.md.

Base URL defaults to https://automationexercise.com. Override with E2E_BASE_URL.

Project Structure

tests/               Functional E2E spec files (*.spec.ts), one directory per feature area
api-tests/           API spec files (*.api.spec.ts), one per resource area, no browser
vr-tests/            Visual regression spec files (*.vr.spec.ts) + baseline snapshots
specs/               Test plans (Markdown) + STATUS.md + seed.spec.ts
utils/
  pageObjects/        Page object classes, BaseAppPage (pages) / BaseComponentPage (modals)
  apiClients/         API client classes, one per resource area, wraps `request`
  fixtures/           Custom Playwright fixtures (account lifecycle, third party blocking)
  testData.ts         Unique data generators
  url.ts              URL constants
playwright.config.ts  Playwright configuration (e2e-chromium, e2e-webkit, api, seed, vr projects)
.github/workflows/    CI pipeline: resolve-pr-run, prepare-playwright-image, static-checks,
                       e2e-chromium, e2e-webkit, visual-regression, api, publish-dashboard, ci-gate

Writing Tests

The coding standard is in the skills, not here. Both load automatically for the files they govern: page objects and specs, screenshots.

Persistent State

specs/STATUS.md — coverage, findings, open decisions. Read it at the start of any session. Reasoning behind the architecture is in docs/decisions.md.

Agent System

Start with playwright-test-manager for any session or coverage question: it owns the cycle and delegates to the four specialists.

AgentRoleSource
playwright-test-managerScope, caps, gates, the whole cyclehand-written
playwright-test-plannerExplores the live app, writes plansinit-agents
playwright-test-generatorImplements one case at a timeinit-agents
playwright-test-reviewerRead-only convention audithand-written
playwright-test-healerDiagnoses failures, edits specsinit-agents

Planner, generator and healer are regenerated after a Playwright upgrade with npx playwright init-agents --loop=claude; re-append the project rules section each one ends with.

Slash commands in .claude/commands/ invoke them: /coverage, /plan, /implement, /review, /heal, /cycle, /baseline, /triage.

CI/CD

GitHub Actions (.github/workflows/ci.yml), stages build → check → end2end:

  1. resolve-pr-run — on push to main, finds the pull request run that already tested the same files
  2. prepare-playwright-image — builds and pushes the execution image every later job runs inside
  3. static-checks — typecheck, lint, format; gates everything after it
  4. e2e-chromium, e2e-webkit, visual-regression, api — in parallel on pull requests; on main only when resolve-pr-run finds nothing to reuse
  5. publish-dashboard — merges the reports, from the reused run or this one, and deploys to Pages, main only
  6. ci-gate — reads every other job's result; the only check branch protection requires

A failed run is repeated with Re-run failed jobs on a pull request, and with Run workflow on main, never a partial re-run there. main takes no direct pushes. Adding a job means adding it to the gate's needs. The reasoning behind each of these is in docs/pipeline.md.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.