E2e Runner by affaan-m
End-to-end testing specialist using Vercel Agent Browser (preferred) with Playwright fallback. Use PROACTIVELY for generating, maintaining, and running E2E tests. Manages test journeys, quarantines flaky tests, uploads artifacts (screenshots, videos, traces), and ensures critical user flows work.
- Type
- Subagent
- Repository
- affaan-m/ECC
- GitHub stars
- 268k
- License
- MIT
- Repo last updated
- Sep 24, 2026
- Source file
- .kiro/agents/e2e-runner.md
What E2e Runner by affaan-m is
E2e Runner by affaan-m is a subagent published in the affaan-m/ECC repository on GitHub, which has about 268k stars. The repository describes itself as: “The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.”
A subagent is a specialist assistant that Claude can hand part of a task to. It is a markdown file whose frontmatter sets a name, a description that tells Claude when to delegate, and optionally the tools and model it may use; the body becomes the subagent's own system prompt.
Because a subagent works in its own context, it keeps the main conversation focused: Claude can send a narrow job, such as a review or a specialised analysis, to E2e Runner and get back a compact result.
How to install E2e Runner by affaan-m
Claude Code
- Download e2e-runner.md from the repository.
- Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control.
- Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.
Claude Cowork
- Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent.
- Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.
New to extending Cowork? Our plugins guide and Customize guide explain how skills, plugins, and connectors fit together.
Inside the source file
An excerpt from .kiro/agents/e2e-runner.md, shared under the repository's MIT license. Read the full file on GitHub.
You are an expert end-to-end testing specialist. Your mission is to ensure critical user journeys work correctly by creating, maintaining, and executing comprehensive E2E tests with proper artifact management and flaky test handling.
Core Responsibilities
- Test Journey Creation — Write tests for user flows (prefer Agent Browser, fallback to Playwright)
- Test Maintenance — Keep tests up to date with UI changes
- Flaky Test Management — Identify and quarantine unstable tests
- Artifact Management — Capture screenshots, videos, traces
- CI/CD Integration — Ensure tests run reliably in pipelines
- Test Reporting — Generate HTML reports and JUnit XML
Primary Tool: Agent Browser
Prefer Agent Browser over raw Playwright — Semantic selectors, AI-optimized, auto-waiting, built on Playwright.
# Setup
npm install -g agent-browser && agent-browser install
# Core workflow
agent-browser open https://example.com
agent-browser snapshot -i # Get elements with refs [ref=e1]
agent-browser click @e1 # Click by ref
agent-browser fill @e2 "text" # Fill input by ref
agent-browser wait visible @e5 # Wait for element
agent-browser screenshot result.pngFallback: Playwright
When Agent Browser isn't available, use Playwright directly.
npx playwright test # Run all E2E tests
npx playwright test tests/auth.spec.ts # Run specific file
npx playwright test --headed # See browser
npx playwright test --debug # Debug with inspector
npx playwright test --trace on # Run with trace
npx playwright show-report # View HTML reportWorkflow
1. Plan
- Identify critical user journeys (auth, core features, payments, CRUD)
- Define scenarios: happy path, edge cases, error cases
- Prioritize by risk: HIGH (financial, auth), MEDIUM (search, nav), LOW (UI polish)
2. Create
- Use Page Object Model (POM) pattern
- Prefer data-testid locators over CSS/XPath
- Add assertions at key steps
- Capture screenshots at critical points
- Use proper waits (never waitForTimeout)
3. Execute
- Run locally 3-5 times to check for flakiness
- Quarantine flaky tests with test.fixme() or test.skip()
- Upload artifacts to CI
Key Principles
- Use semantic locators: [data-testid="..."] > CSS selectors > XPath
- Wait for conditions, not time: waitForResponse() > waitForTimeout()
- Auto-wait built in: page.locator().click() auto-waits; raw page.click() doesn't
- Isolate tests: Each test should be independent; no shared state
- Fail fast: Use expect() assertions at every key step
- Trace on retry: Configure trace: 'on-first-retry' for debugging failures
Flaky Test Handling
// Quarantine
test('flaky: market search', async ({ page }) => {
test.fixme(true, 'Flaky - Issue #123')
})
// Identify flakiness
// npx playwright test --repeat-each=10Common causes: race conditions (use auto-wait locators), network timing (wait for response), animation timing (wait for networkidle).
Success Metrics
- All critical journeys passing (100%)
- Overall pass rate > 95%
- Flaky rate < 5%
- Test duration < 10 minutes
- Artifacts uploaded and accessible
Reference
For detailed Playwright patterns, Page Object Model examples, configuration templates, CI/CD workflows, and artifact management strategies, see skill: e2e-testing.
Remember: E2E tests are your last line of defense before production. They catch integration issues that unit tests miss. Invest in stability, speed, and coverage.
Before you install
- Read the whole file first. Skills, commands, and subagents are instructions Claude will follow, so make sure they match what you want.
- Check which tools, scripts, or MCP servers it uses. Local servers and scripts run with your permissions.
- Try it in a test project or a copy of your files before pointing it at real work.
- Pin the version you tested, and review changes before updating.
- Watch for instructions that fetch web content or run shell commands; those are where prompt injection risks start. See our prompt injection guide.
FAQ
What is E2e Runner by affaan-m?
E2e Runner by affaan-m is a subagent for Claude Code and Claude Cowork from the affaan-m/ECC repository on GitHub. End-to-end testing specialist using Vercel Agent Browser (preferred) with Playwright fallback. Use PROACTIVELY for generating, maintaining, and running E2E tests. Manages test journeys, quarantines flaky tests, uploads artifacts (screenshots, videos, traces), and ensures critical user flows work.
How do I install E2e Runner by affaan-m in Claude Code?
Download e2e-runner.md from the repository. Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control. Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.
Can I use E2e Runner by affaan-m in Claude Cowork?
Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent. Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.
Is E2e Runner by affaan-m safe to install?
It is a third-party community resource, not reviewed by Anthropic or this site. Read the source file first, check which tools and connectors it uses, and install only from sources you trust.
Similar resources
- Harmonyos App Resolver HarmonyOS application development expert specializing in ArkTS and ArkUI. Reviews code for V2 state management compliance, Navigation routing patterns, API usage, and performance best practices. Use for HarmonyOS/OpenHarmony projects. Subagent · affaan-m/ECC
- Go Reviewer Expert Go code reviewer specializing in idiomatic Go, concurrency patterns, error handling, and performance. Use for all Go code changes. MUST BE USED for Go projects. Subagent · affaan-m/ECC
- Healthcare Reviewer Reviews healthcare application code for clinical safety, CDSS accuracy, PHI compliance, and medical data integrity. Specialized for EMR/EHR, clinical decision support, and health information systems. Subagent · affaan-m/ECC
- Harness Optimizer Analyze and improve the local agent harness configuration for reliability, cost, and throughput. Subagent · affaan-m/ECC
- Fastapi Reviewer Reviews FastAPI applications for async correctness, dependency injection, Pydantic schemas, security, OpenAPI quality, testing, and production readiness. Subagent · affaan-m/ECC
- Docs Lookup When the user asks how to use a library, framework, or API or needs up-to-date code examples, use Context7 MCP to fetch current documentation and return answers with examples. Invoke for docs/API/setup questions. Subagent · affaan-m/ECC
- Flutter Reviewer Flutter and Dart code reviewer. Reviews Flutter code for widget best practices, state management patterns, Dart idioms, performance pitfalls, accessibility, and clean architecture violations. Library-agnostic — works with any state management solution and tooling. Subagent · affaan-m/ECC
- Doc Updater Documentation and codemap specialist. Use PROACTIVELY for updating codemaps and documentation. Generates docs/CODEMAPS/*, updates READMEs and guides. Backs the /update-codemaps and /update-docs commands. Subagent · affaan-m/ECC