Quality Gates
Definition of Done
- • All tests pass (
cargo test) - • No clippy warnings (
cargo clippy -- -D warnings) - • Code formatted (
cargo fmt --check) - • No hardcoded paths or credentials
- • Public APIs have doc comments
- • Error cases handled, not ignored
Build & Test Commands
bash
cargo build # Build cargo test # Run all tests cargo clippy # Lint cargo fmt --check # Format check cargo check # Type check only
- •ALWAYS run
cargo testafter code changes - •ALWAYS run
cargo checkbefore committing - •ALWAYS run
cargo clippybefore opening PRs
Hook Testing
- •After modifying any hook script in
.claude/hooks/, runbash tests/hooks/run_hook_tests.sh - •When creating test files, be aware that
protect-hooks.shmay block writes to hook-adjacent paths — if blocked, report to team lead immediately - •Ensure git test environments have
user.emailanduser.nameconfigured
Agent Output Schemas
When spawning agents, expect structured output:
- •coder:
{ files_changed: [], tests_added: [], tests_passing: bool } - •tech-lead:
{ status: APPROVED|BLOCKED, critical: [], warnings: [] } - •reviewer:
{ issues: [], suggestions: [], approved: bool } - •qa:
{ tests_run: int, tests_passed: int, edge_cases: [] }
Review Pipeline
- •Coder completes implementation
- •
cargo test+cargo clippyruns (hook, deterministic) - •Tech-lead reviews code (spawned as subagent)
- •If BLOCKED → coder fixes and re-submits
- •If APPROVED → orchestrator commits
- •User reviews via
git-review(review gate hook)
CI/CD Integration
- •GitHub Actions should run:
cargo test,cargo clippy,cargo fmt --check - •The review gate (
git-review gate check) can run in CI as a required check - •Hook scripts in
.claude/hooks/are for local Claude enforcement only — not CI - •CI checks are deterministic and repeatable; hook checks add agent-specific rules