From ct
Uncovers edge cases, test coverage gaps, and bugs via phased analysis of code and tests. Guides gap identification, iterative test writing, and bug documentation.
How this skill is triggered — by the user, by Claude, or both
Slash command
/ct:bugmagnetThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Systematic test coverage analysis and bug discovery.
Systematic test coverage analysis and bug discovery.
Based on gojko/bugmagnet-ai-assistant.
🔍 ANALYSE → Understand code and existing tests
📊 GAP → Identify missing coverage
✍️ WRITE → Implement tests iteratively
🔬 ADVANCED → Deep edge case exploration (optional)
📋 SUMMARY → Document findings and bugs
Interactive mode (default): STOP and wait for user confirmation between phases. Autonomous mode: When invoked by another agent (e.g. code-reviewer), skip all STOP points and proceed through all phases automatically. Present the full summary at the end instead of pausing for input.
STOP — Wait for user input. (Skip in autonomous mode.)
Evaluate missing coverage using edge-cases.md:
Categorise: High (core, errors, boundaries) → Medium (interactions, state) → Low (rare, performance). Present analysis with specific examples.
STOP — Ask user which tests to implement. (Skip in autonomous mode — implement all high-priority tests.)
For each test, highest priority first:
On failure: test expectation wrong → update test. Bug discovered → create skipped test with documentation. Need more context → try 2 more variations.
When bug found: create minimal reproduction, explore surrounding territory (bugs cluster), document in skipped test — DO NOT FIX, only document. Include: brief description, root cause, code location, expected vs actual, proposed fix.
Maximum 3 attempts per test — document and move on.
STOP — Ask user if they want advanced coverage. (Skip in autonomous mode — proceed to advanced if high-priority gaps remain.)
Create separate test suite: "bugmagnet session <date>"
Work through edge-cases.md comprehensively — complex interactions, error handling, numeric/date/string/collection edge cases, state transitions, domain-specific cases.
## Test Coverage Summary
**Tests Added:** X total (Y passing, Z skipped/bugs)
**Bugs Discovered:**
1. Bug name — file:line — root cause — proposed fix
npx claudepluginhub pvillega/claude-templates --plugin ctSurveys test suites across five phases: unit, integration, E2E (browser), fuzz coverage gaps, and test quality. Produces findings and proposes tickets for remediation.
Assesses three-layer test coverage (unit/integration/E2E) by mapping source code to tests, identifying gaps, and recommending new tests.