How hamc/blastproof works
blastproof is a local/CI AI-assisted end-to-end testing agent: users configure a project, describe tests in YAML, and run them against a real browser. The run path checks prerequisites, optionally narrows tests to those affected by a diff, establishes authentication, executes browser actions judged by a model, then scores and reports the gate result. Separate capabilities scaffold setup and draft uncovered-route tests. The map follows README statements and SOURCE INDEX references; several unsampled subsystems are represented by their exact directories, so their internal wiring is not inferred.
Main entry points: run.ts Run command · plan.ts Plan command · executor.ts Test executor · brain.ts Agent and judge
Components 24
Project setup
- Project init
src/commands/init.ts - Configuration
src/config.ts
Test selection
- YAML test files
src/runner/testfile.ts - Run command
src/commands/run.ts - Diff analysis
src/diff.ts - Impact mapping
src/impact.ts
Browser execution
- Preflight checks
src/preflight.ts - Session authentication
src/auth.ts - Test executor
src/runner/executor.ts - Browser actions
src/runner/actions.ts - Accessibility snapshots
src/runner/snapshot.ts - Secrets and env
src/runner/env.ts - Run budget
src/runner/budget.ts
AI and planning
- Agent and judge
src/llm/brain.ts - Model prompts
src/llm/prompts.ts - Action schemas
src/llm/schemas.ts - Model provider
src/llm/provider.ts - Test planner
src/planner.ts - Plan command
src/commands/plan.ts
Results and reports
- Run scoring
src/report/score.ts - HTML and JUnit
src/report/html.ts - Run warnings
src/report/warnings.ts
Other components
- Developer / CI
- CLI
src/cli.ts
Connections 31
- Developer / CI → CLI: invokes
- CLI → Project init: dispatches
src/cli.ts - CLI → Run command: dispatches
src/cli.ts - CLI → Plan command: dispatches
src/cli.ts - Project init → Configuration: scaffolds
src/commands/init.ts - Developer / CI → YAML test files: writes
- Run command → Configuration: loads
src/commands/run.ts - Run command → YAML test files: discovers and parses
src/commands/run.ts - Run command → Diff analysis: checks changes
src/commands/run.ts - Run command → Impact mapping: selects affected tests
src/commands/run.ts - Run command → Preflight checks: checks prerequisites
src/commands/run.ts - Run command → Session authentication: prepares session
src/commands/run.ts - Run command → Test executor: executes tests
src/commands/run.ts - Test executor → Browser actions: performs actions
src/runner/executor.ts - Test executor → Accessibility snapshots: reads snapshots
src/runner/executor.ts - Test executor → Secrets and env: resolves and masks
src/commands/run.ts - Test executor → Agent and judge: requests judgments
src/runner/executor.ts - Agent and judge → Model prompts: builds prompts
src/llm/brain.ts - Agent and judge → Action schemas: validates output
src/llm/brain.ts - Agent and judge → Run budget: bounds calls
src/llm/brain.ts - Preflight checks → Model provider: checks model
src/preflight.ts - Agent and judge → Model provider: uses model
- Run command → Run scoring: scores results
src/commands/run.ts - Run command → HTML and JUnit: writes reports
src/commands/run.ts - Run command → Run warnings: collects warnings
src/commands/run.ts - Plan command → Configuration: loads
src/commands/plan.ts - Plan command → Test planner: drafts tests
src/commands/plan.ts - Plan command → Impact mapping: finds uncovered routes
src/commands/plan.ts - Plan command → Preflight checks: checks prerequisites
src/commands/plan.ts - Plan command → YAML test files: reads test coverage
src/commands/plan.ts - Plan command → Run scoring: reports score
src/commands/plan.ts