agentic-browser-testing
FreeNo executable scriptsNot checkedGoal-driven E2E testing where a browser agent (Playwright MCP / computer-use) reads a natural-language goal and explores the app via the accessibility tree to…
by petrkindlmann★ 317 GitHub starsAbout this skill
Quick Route
| Situation | Go to |
|---|---|
| Stand up a goal-driven run from scratch | Discovery + references/setup.md |
| Decide agentic vs scripted for a given flow | Fit: Intent-Driven vs Scripted |
| Agent passes one run, fails the next | Repeatability |
| "How does it click without screenshots?" | Interaction Model |
| Runs are slow / burning tokens | Cost and Latency |
| Agent reports false success | Success Assertion (the Oracle) |
| Flow is stable — make it permanent | Graduation → references/graduation-and-ci.md |
| Block a merge on the goal | CI Gating → references/graduation-and-ci.md |
| Canvas / no accessibility tree | Canvas Fallback → references/graduation-and-ci.md |
Discovery Questions
First, check .agents/qa-project-context.md in the project root and skip anything it already
answers (stack, environments, seed/reset tooling, model access).
- Which flow, and how often does its UI change? Fast-changing/experimental UI favors intent-driven; a stable critical path (login) favors scripted. This decides the whole approach.
- Is there a seeded fixture and a way to reset state? Repeatable comparisons require controlled data and a per-run reset. If neither exists, that is step zero.
- Can you deep-link past auth to a seeded entry point? Re-driving login every run is the biggest avoidable cost; a seeded entry URL scopes the goal and cuts steps.
- What is the unambiguous success oracle? Specific account text, a
/dashboardURL, an order number — plus a forbidden state. "No error" is not an oracle. - Does the target render to canvas / WebGL? No accessibility tree means snapshot-first won't work; plan the vision fallback or instrument the canvas with ARIA.
- Which model and budget? Choose an available model version and enforce step, time and token budgets up front. Record the installed adapter and actual model returned by the service.
Core Principles
Choose intent-driven exploration where it helps. The agent reads a goal and chooses controls from the current accessibility tree. Compare its observed cost, latency and repeatability with scripted checks before using it for a critical path. Role-based scripted locators also survive many layout and CSS changes.
Control variance and measure repeatability. Pin supported model settings, reset the fixture, bound steps and wall time, and evaluate a separate oracle. Temperature zero and a pinned model reduce some variability; they do not guarantee identical navigation or verdicts. Run repeated healthy and broken controls before enabling a CI gate.
The oracle lives outside the agent. Never let the LLM self-grade "looks good." Success is a checkable assertion against the final
browser_snapshot— specific expected text, a URL, AND a forbidden-state negative check — evaluated by your harness, not the model.Accessibility tree first, pixels last.
browser_snapshotreturns roles, refs, and accessible names in a machine-readable form. Screenshots, pixel coordinates, vision, and OCR are a scoped last resort for canvas only, never the default.Graduation is the goal, not perpetual agent runs. Once a flow is stable, promote the run to a durable scripted
tests/*.spec.tswith role-based locators. An agent that has been green for two weeks should become a fast, free regression test — keep the agent for exploration, not for guarding a settled path.
Fit: Intent-Driven vs Scripted
The decision is per-flow, not per-project. Run risk-based-testing first if you need the
risk map; this table is the routing rule once you have it.
| Flow characteristic | Use | Why |
|---|---|---|
| Stable, high-frequency critical path (login, payment) | Scripted + pinned (playwright-automation) |
Runs every PR with a maintained sequence and explicit assertions. |
| Fast-changing / experimental UI (a dashboard that churns weekly, a redesign in flight) | Agentic / intent-driven | Selectors would break constantly; a goal survives layout churn. |
| Hard-to-locate flow you can't reliably select | Agentic | The agent finds the control by role/name instead of you reverse-engineering a selector. |
| Exploratory smoke / "does the happy path still work at all" | Agentic | One NL goal covers a lot of ground without a maintained script. |
| Anything in CI that must never falsely pass | Scripted, OR agentic **with a hard ora |
Install agentic-browser-testing in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
Bundled files
FAQ
What does the agentic-browser-testing skill do?
Goal-driven E2E testing where a browser agent (Playwright MCP / computer-use) reads a natural-language goal and explores the app via the accessibility tree to assert outcomes — no pre-written script. Covers when intent-driven beats scripted, making agent runs repeatable and bounded (pinned model, temperature 0, seeded data, bounded steps, explicit success assertion, snapshot-not-pixel), cost/latency control, the accessibility-tree-first interaction model, CI gating, and graduating a stable run into a scripted Playwright test. Use when: "agentic browser test," "goal-driven browser test," "let an agent explore the app," "natural-language E2E," "browser agent smoke test," "Playwright MCP test." Not for: Writing/maintaining deterministic scripted Playwright tests — that is playwright-automation. Testing your product's OWN LLM features — that is ai-system-testing. Related: playwright-automation, ai-system-testing, exploratory-testing, test-reliability, qa-project-context.
How do I install the agentic-browser-testing skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the agentic-browser-testing skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
by Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
by Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
by Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
by Anthropic