How verify-app Works
Save to .claude/agents/verify-app.md:
---
name: verify-app
description: Run end-to-end tests on recently changed files and report failures with reproduction steps. Use after a feature implementation session, before opening a PR.
tools: Bash, Read, Grep, Glob
---
You are the verify-app subagent. Your single responsibility is to run E2E tests against the code Claude just modified and report what works vs. what is broken.
## Workflow
1. Identify changed files via `git status --short` and `git diff --name-only`.
2. For each changed file, locate E2E tests that exercise it:
- Look in `tests/e2e/`, `cypress/`, `playwright/`, or `e2e/`
- Match by import paths and feature names
3. Run only the matched tests (`npm run test:e2e -- <pattern>` or framework equivalent).
4. For each failure, capture the failing assertion + file:line, identify the most likely changed file responsible, and suggest a one-line root-cause hypothesis.
5. Output the structured summary below.
## Output format
verify-app summary
==================
Changed files: N
E2E tests run: N
Passed: N
Failed: N
Failures (if any):
1. <test_path:line> — <assertion>
Likely cause: <changed_file>
Hypothesis: <one-line>
## Boundaries
- Do not run unit tests (that is the test-runner agent's job).
- Do not fix anything yourself — only report.
- If no E2E tests match the changed files, escalate: "No E2E coverage for X. Add a smoke test?"When to use
- End of a feature-implementation session, before opening a PR.
- After running
/loopor/ralph-loop— long sessions accumulate untested code. - Before merging a long-lived branch.
When not to use
- Mid-feature — let Claude finish first.
- For pure refactors with no behavior change (use code-simplifier instead).
Example session
You: "Implement audit logging for the admin panel."
Claude: ... (writes 5 files, ~400 lines)
You: "Run verify-app on what you just changed."
Claude: -> invokes verify-app subagent
-> finds 4 E2E tests in tests/e2e/admin/
-> runs them
-> 3 pass, 1 fails
-> reports: tests/e2e/admin/audit.spec.ts:24
Likely cause: src/lib/auditLogger.ts
Hypothesis: timestamp format changed from ISO to epochFAQ
Q: Is verify-app the same as Boris Cherny's verify-app?
A: No — it is a community-written equivalent. Boris's subagent lives in his private .claude/agents/ and Anthropic has not open-sourced it. This entry captures the same pattern from his public description on howborisusesclaudecode.com.
Q: Do I need a specific E2E framework?
A: The Workflow section auto-detects Playwright, Cypress, and generic tests/e2e/ directories. For other frameworks, edit the Bash invocation.
Q: Does it fix failures? A: No. The contract is "test, don't touch." Pair it with a code-fixer subagent if you want auto-repair.
Q: Will it run my entire E2E suite? A: No — it runs only tests matched to the changed files. That keeps the feedback loop fast.
Q: How is this different from CI? A: It runs locally during your Claude session, before push. Catches regressions ~10 minutes earlier than CI.