Deep verification that feature/module works end-to-end according to spec
Performs deep end-to-end verification that a feature works completely according to specification.
/plugin marketplace add packlikez/claude-code-dev-plugin/plugin install dev@packlikez-dev-plugins<target> (feature name, module, endpoint, component)Deep verification that target works completely according to spec or understood functionality.
Supports large features with checkpointing and context management.
EXPLORE → CLARIFY → CONFIRM → VERIFY (chunked) → REPORT
Estimate feature size:
| Size | Files | Action |
|---|---|---|
| Small | <5 | Execute directly |
| Medium | 5-15 | Chunk verification, checkpoint after each |
| Large | 15+ | Delegate exploration to agents, chunk all phases |
Break verification into independent chunks:
CHUNK 1: Spec & Backend verification
CHUNK 2: Frontend verification
CHUNK 3: Test verification
CHUNK 4: Data flow verification
CHUNK 5: Edge cases & error handling
After each chunk:
.claude/ensure-progress.mdWrite to .claude/ensure-progress.md:
# Ensure Progress: {target}
Updated: {timestamp}
## Completed Chunks
- [x] Chunk 1: Spec & Backend - 8/8 passed
- [x] Chunk 2: Frontend - 5/5 passed
- [ ] Chunk 3: Tests - IN PROGRESS
## Current Chunk
Chunk: 3 - Test verification
Progress: 12/20 checks
Last check: API test for POST /users
## Findings So Far
- PASS: All AC implemented
- PASS: All endpoints exist
- FAIL: Missing test for password reset
- WARN: E2E test flaky (1/3 fails)
## Remaining
- Chunk 3: 8 more checks
- Chunk 4: Data flow (15 checks)
- Chunk 5: Edge cases (10 checks)
## Context Reload (if resuming)
Read: specs/features/{target}.md
Read: .claude/ensure-progress.md
If context compacts or new session:
/dev:ensure {target} --resume
This reads .claude/ensure-progress.md and continues from last checkpoint.
Thoroughly explore the target to understand every detail.
# Count related files
find . -name "*{target}*" | wc -l
| Count | Action |
|---|---|
| <5 | Explore directly |
| 5-15 | Use grep summaries, read key files only |
| 15+ | Delegate to Explore agent |
Use Task tool with Explore agent:
"Explore all files related to {target} feature.
Find: specs, backend code, frontend code, tests.
Return: file list with brief purpose of each.
Do not read full content, just identify files."
# Spec
find . -name "*{target}*" -path "*/specs/*"
# Backend (just list, don't read yet)
find . -name "*{target}*" -path "*/src/*" -name "*.ts" | grep -v test
# Frontend
find . -name "*{target}*" -path "*/src/*" -name "*.tsx"
# Tests
find . -name "*{target}*" -path "*/tests/*"
# API routes (grep for mentions)
grep -rln "{target}" src/routes/ src/api/ 2>/dev/null
Don't read full files. Extract key info:
# Get function names only
grep -n "export.*function\|export.*const.*=" {file}
# Get endpoint definitions only
grep -n "router\.\|app\.\|@Get\|@Post" {file}
# Get component names only
grep -n "export.*function\|export default" {file}
# Get test names only
grep -n "describe\|it\|test(" {file}
Only read full file when needed for specific check.
TARGET: {name}
Files found: {n} (Small/Medium/Large)
SPEC SUMMARY:
- AC count: {n}
- Edge cases: {n}
- Screens: {n}
IMPLEMENTATION SUMMARY:
- Endpoints: {n} in {files}
- Components: {n} in {files}
- Services: {n} in {files}
TESTS SUMMARY:
- Unit: {n} files, {n} tests
- API: {n} files, {n} tests
- E2E: {n} files, {n} tests
INITIAL GAPS:
- {any obvious missing pieces}
Save to .claude/ensure-progress.md before continuing.
Use AskUserQuestion to understand what exactly needs verification.
Scope: "What aspect do you want to ensure?"
Depth: "How thorough should verification be?"
Focus areas: "Any specific concerns?"
Present findings and get confirmation before proceeding.
ENSURE: {target}
FOUND:
- Spec: {file} with {n} acceptance criteria
- Backend: {n} endpoints in {files}
- Frontend: {n} components in {files}
- Tests: {n} unit, {n} API, {n} E2E
WILL VERIFY:
1. All {n} acceptance criteria from spec
2. All endpoints respond correctly
3. All components render with correct data
4. Data flows: Input → API → DB → Response → UI
5. Error cases handled
6. Edge cases covered
ESTIMATED: {n} checks
Proceed? (Yes/No/Modify scope)
Systematically verify every detail. Use TodoWrite to track progress.
Use TodoWrite to create verification checklist:
Todos:
- [ ] Chunk 1: Spec vs Backend
- [ ] Chunk 2: Frontend verification
- [ ] Chunk 3: Test coverage
- [ ] Chunk 4: Data flow
- [ ] Chunk 5: Edge cases & errors
For each acceptance criterion:
AC: "User can register with email and password"
CHECK:
[ ] API endpoint exists: POST /api/auth/register
[ ] Endpoint accepts: { email, password }
[ ] Endpoint validates: email format, password length
[ ] Endpoint returns: { user: { id, email }, token }
[ ] DB stores: users table with hashed password
[ ] Frontend form: email input, password input, submit
[ ] Frontend shows: success/error message
After chunk: Update .claude/ensure-progress.md, mark todo complete.
[ ] All screens from spec exist
[ ] Components render correctly
[ ] Forms have proper validation
[ ] Loading states shown
[ ] Error states handled
After chunk: Checkpoint progress.
[ ] Unit tests exist for all functions
[ ] API tests cover all endpoints
[ ] E2E tests cover all user flows
[ ] No weak assertions (run detection)
[ ] Tests actually pass
# Run tests
npm test -- --grep "{target}"
# Weak assertion check
grep -rEn "(toBeDefined|toExist|toBeTruthy)\(\)" tests/**/*{target}*
After chunk: Checkpoint progress.
Trace ONE complete flow (don't read all files):
INPUT: email="test@example.com"
1. FRONTEND → grep for form submit handler
2. API → grep for endpoint handler
3. DB → grep for database call
4. RESPONSE → check response shape
5. UI → check success display
Verify input value appears at each step.
After chunk: Checkpoint progress.
EDGE CASES:
[ ] Empty inputs handled
[ ] Invalid format handled
[ ] Boundary values handled
ERRORS:
[ ] 400: Validation errors shown
[ ] 401: Redirect to login
[ ] 403: Access denied
[ ] 404: Not found
[ ] 500: Generic error
[ ] Network: Offline handling
Use incomplete-code-detection skill. Scan for placeholder/mock code:
# Empty functions
grep -rEn "=> \{\}|\{[\s]*\}" src/**/*{target}*
# TODO/FIXME left in code
grep -rEn "(TODO|FIXME|HACK)" src/**/*{target}*
# Empty event handlers (onClick={() => {}})
grep -rEn "on[A-Z].*=>[\s]*\{\}" src/**/*{target}*
# Console.log (debug code)
grep -rEn "console\.(log|debug)" src/**/*{target}*
# Mock/test data in production
grep -rEn "(test@|example\.com|fake|mock)" src/**/*{target}* | grep -v "\.test\.\|\.spec\."
# Empty catch blocks
grep -rEn "catch.*\{[\s]*\}" src/**/*{target}*
# Hardcoded values
grep -rEn "localhost|127\.0\.0\.1" src/**/*{target}*
ANY match = FAIL (unless intentional with documented reason)
# Run related tests
npm test -- --grep "{target}"
# E2E specific
npx playwright test --grep "{target}"
Update final progress:
# Ensure Complete: {target}
All chunks verified:
- [x] Chunk 1: Spec vs Backend - PASS
- [x] Chunk 2: Frontend - PASS
- [x] Chunk 3: Tests - 1 FAIL (weak assertion)
- [x] Chunk 4: Data flow - PASS
- [x] Chunk 5: Edge cases - PASS
ENSURE COMPLETE: {target}
VERIFIED:
- Acceptance Criteria: 8/8
- Endpoints: 3/3
- Components: 5/5
- Data Flow: Verified (Input → DB → UI)
- Edge Cases: 6/6
- Error Handling: All codes covered
- Tests: 24/24 passing
STATUS: FULLY WORKING
All functionality works end-to-end according to spec.
ENSURE FAILED: {target}
PASSED: 18/24 checks
FAILED:
1. AC3: "Password reset email" - Not implemented
- Missing: POST /api/auth/reset-password
- Missing: ResetPasswordForm component
- Action: Implement password reset flow
2. Edge case: "Expired token" - No handling
- API returns 401 but UI shows generic error
- Action: Add specific expired token UI
3. E2E: "login-flow.spec.ts" - Flaky
- Fails 1/3 runs
- Action: Add proper wait conditions
NEXT STEPS:
1. /dev:backend user-registration (implement reset)
2. Fix token expiry UI
3. Stabilize E2E test