agentleFS
AishwaryShrivastavAishwaryShrivastav/vibe-testing/CLAUDE.md

vibe-testing

CLAUDE.md16 starsChanged 7 months agoMITView on GitHub

This is the vibe-test source repository. It's an MCP server + CLI for AI-powered browser testing. vibe-test gives AI coding assistants (Claude Code, Cursor, Windsurf, etc.) 14 browser testing tools via MCP. When a user asks "test the login flow", the AI uses these tools to: 1. Read the source code (understand real field names, routes, selectors) 2. Open a real Playwright browser 3. Execute test steps, take screenshots 4. Report what works and what breaks — including regressions vs…

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:

    Read the source code (understand real field names, routes, selectors)

    line 8

≈ “Common” is an estimate: at least 1 in 5 of the 25,680 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

Vibe Test — Code-Aware Browser Testing Agent

This is the vibe-test source repository. It's an MCP server + CLI for AI-powered browser testing.

What This Project Does

vibe-test gives AI coding assistants (Claude Code, Cursor, Windsurf, etc.) 14 browser testing tools via MCP. When a user asks "test the login flow", the AI uses these tools to:

  1. Read the source code (understand real field names, routes, selectors)
  2. Open a real Playwright browser
  3. Execute test steps, take screenshots
  4. Report what works and what breaks — including regressions vs the previous run

Architecture

src/
├── cli.ts              # CLI entry: vibe-test run/converge/init/reset/report + --mcp flag
├── mcp-server.ts       # MCP server (14 tools via JSON-RPC stdio)
└── engine/
    ├── index.ts        # VibeTester orchestrator (run + converge, emits snapshot_diff)
    ├── converge.ts     # Iterative coverage loop (baseline + follow-up rounds)
    ├── context/        # Static code analysis (no browser)
    │   ├── index.ts    # Builds ProductModel; writes route manifest + diffs scans
    │   ├── detector.ts # Framework detection + monorepo detection + port auto-detect
    │   ├── router.ts   # Route parsing per framework
    │   ├── extractor.ts # Extract forms, buttons, dialogs, features
    │   ├── test-reader.ts # Parse existing Jest/Cypress/Playwright tests
    │   ├── gap-analyzer.ts # Score untested routes by priority
    │   └── enricher.ts # Generate TestScenarios from gaps
    ├── browser/        # Playwright execution
    │   ├── runner.ts   # Execute scenarios step-by-step
    │   ├── explorer.ts # Click everything, monitor APIs
    │   └── verifier.ts # Heuristic pass/fail (no LLM)
    ├── memory/         # Persist learning across runs
    │   ├── index.ts    # MemoryManager — selectors, timings, credentials, flaky routes
    │   └── manifest.ts # Route manifest + run snapshot diffing (regression detection)
    ├── reporter/       # Generate HTML reports
    └── coverage-gaps.ts # Post-execution gap analysis

MCP Tools (13)

ToolPurpose
scan_codebaseAnalyze project → routes, forms, coverage gaps, route_changes since last scan
get_contextReturn relevant source files for a feature (real selectors)
loginAuth in real browser, capture tokens
scan_page_elementsDiscover interactive elements on a page
explore_pageClick everything, monitor APIs, report breakage
execute_scenarioRun multi-step test flows
get_coverageView coverage map and gaps
suggest_testsGet prioritized, executable scenarios
take_screenshotVisual verification
generate_reportHTML report with screenshots
run_full_testOne-shot: scan → execute → explore → report (+ snapshot_diff)
run_convergeIterative testing until thresholds (+ snapshot_diff)
cleanupClose browsers

Development

npm run build      # tsc compile → dist/
npm run dev        # Run CLI via tsx (no compile)
npm run mcp        # Run MCP server via tsx
npm test           # vitest — 63 tests (config, framework, manifest, ...)

Node 20+ required (vitest 4.x).

Key Design Decisions

  • No LLM for verification — heuristic pass/fail (URL changes, toasts, API errors). The editor's LLM is the brain.
  • get_context is the key tool — returns actual source code so the LLM knows real selectors instead of guessing
  • Session state — MCP server maintains a session between tool calls (browser, auth context, results)
  • Self-improving — .vibe/memory.json persists working selectors, flaky flows, credentials across runs
  • Regression detection — .vibe/route-manifest.json and .vibe/run-snapshot.json are diffed every scan/run; route_changes and snapshot_diff are surfaced on the returned results so the editor can flag newly-failing routes without scrolling the report
  • Headless by default in MCP mode — when launched via --mcp, the browser runs headless so editor sessions aren't disrupted; CLI stays headed
  • init command — one command configures ALL detected editors (Cursor, Claude Code, Windsurf, VS Code, Roo)

Publishing

npm run build
npm version patch    # or minor/major
npm publish          # publishes to npm as 'vibe-testing'

Tagged releases trigger a GitHub Actions workflow that also publishes to the official MCP Registry (OIDC trusted publishing).

A Dockerfile (Node 20 + Chromium) is included for Glama.ai quality scoring and container-based MCP deployments.

Users run: npx vibe-testing@latest init in their project.

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.

Reviews can't be read right now.

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.