Built-in browser automation and E2E verification workflow. Use for Claude /wf-browser, Codex $wf-browser or /skills wf-browser, Browser Use, Playwright, Chrome DevTools/CDP, screenshots, forms, UI verification, and browser-visible acceptance.
التثبيت
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
Built-in browser automation and E2E verification workflow. Use for Claude /wf-browser, Codex $wf-browser or /skills wf-browser, Browser Use, Playwright, Chrome DevTools/CDP, screenshots, forms, UI verification, and browser-visible acceptance.
WF Browser
This skill is the single Browser E2E entry. Do not use or create a separate
browser E2E skill. The browser evidence contract lives here plus
Harness/specs/protocols/HARNESS_BRIDGE.md.
Invocation
Claude Code: use /wf-browser <task> or select the wf-browser skill.
Codex CLI or IDE: use $wf-browser <task> or /skills then choose wf-browser.
OpenCode: use /wf-browser <task>.
Load
CLAUDE.md
Harness/MEMORY.md index only per Memory Preflight
Harness/README.md
Harness/specs/protocols/HARNESS_BRIDGE.md
Project run/build/test instructions
Official Browser Use skill text from browser-use skill when Browser Use is used
Cache Discipline
Follow Harness/specs/runtime/context-loading.md#Cache-First Context Contract: keep stable
workflow docs first, then append only the current URL, selectors, concise browser
state, screenshot paths, trace paths, and failing assertions. Do not paste full
accessibility trees, browser logs, screenshots, videos, or network dumps into
task state.
Browser Evidence Contract
Every browser-visible claim needs real browser evidence:
URL and viewport/browser scope.
Stable selector contract using data-testid and accessible labels/roles.
Real interaction evidence from Browser Use, Playwright, Chrome DevTools/CDP,
or documented manual browser checks.
Console and network checks for runtime exceptions, failed requests, and
frontend-backend side effects.
Screenshot, trace, video, state snapshot, or command output path.
AC-by-AC validation matrix when acceptance criteria exist.
No data-testid or stable accessible selector, no UI acceptance. No API
contract, no backend integration acceptance.
Controllable UI Contract
UI built for browser control must expose targetable, user-meaningful controls:
Category
Required control surface
Inputs
<label> association or aria-label, data-testid, disabled/invalid states, deterministic placeholder only as fallback
Buttons
accessible name, data-testid, disabled/loading state, no icon-only button without aria-label
Filters
stable test id for input/menu/chip, selected state, clear/reset control
Rows/items
stable row/item test id plus durable item key such as data-row-id; avoid index-only targeting
Empty state
visible empty container with data-testid="empty-state" or feature-specific equivalent
Error state
inline error/toast/banner with stable test id and accessible role when appropriate
Loading state
stable spinner/skeleton/progress test id; verify duplicate submit prevention
Required coverage targets: inputs, buttons, filters, rows, empty/error/loading states.
Selector priority:
data-testid
accessible labels/roles
visible text for stable user-facing copy
Do not use generated class names, brittle CSS chains, XPath, DOM index selectors,
or raw coordinates as the primary test contract. Coordinates are acceptable only
after locating an element through the accessibility tree or when testing canvas
or other non-DOM UI.
Browser Use CLI
Use the current script-style Browser Use CLI; old browser-use open/state/click/screenshot/input/wait subcommands are removed from the current CLI and must not be used in new docs or tests.
For local Chrome connection problems, run browser-use --doctor. If Chrome asks
to allow remote debugging, stop and ask the user to approve the browser prompt.
Playwright Test Pattern
Prefer Playwright for repeatable E2E tests and Browser Use/CDP for exploratory
or interactive checks.