test-first-bugs

Solid

This skill should be used when the user reports a bug, describes unexpected behavior, says something is "broken", "not working", "failing", mentions an "error", "issue", or "problem" in code, or asks to "fix" something. Enforces test-driven bug fixing workflow.

Testing & QA 233 stars 44 forks Updated today MIT

Install

View on GitHub

Quality Score: 89/100

Stars 20%
79
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Test-first bug fixing Enforce a disciplined bug-fixing workflow that prevents regression and parallelizes fix attempts. ## Core workflow When a bug is reported, follow these steps in order: ### Phase 1: Reproduce and document 1. **Understand the bug** — Gather details about expected vs actual behavior 2. **Identify the test location** — Determine where tests live in the project (check for `tests/`, `__tests__/`, `spec/`, `*.test.*`, `*.spec.*` patterns) 3. **Write a failing test** — Create a test that demonstrates the bug ### Phase 2: Fix with subagents 4. **Launch fix subagents** — Use the Task tool with `subagent_type=general-purpose` to attempt fixes 5. **Run the test** — Verify the fix by running the specific test 6. **Iterate if needed** — If test still fails, launch additional subagents with new approaches ### Phase 3: Verify and complete 7. **Run full test suite** — Ensure no regressions were introduced 8. **Report success** — Confirm the bug is fixed with passing test as proof ## Writing the failing test ### Test naming convention Name the test to describe the bug: ```python # Python (pytest) def test_user_login_fails_when_email_has_uppercase(): ... # Python (unittest) def test_should_handle_empty_input_without_crashing(self): ... ``` ```javascript // JavaScript (Jest/Vitest) it('should not crash when input array is empty', () => { ... }); test('handles special characters in username', () => { ... }); ``` ```typescript // TypeScript describe(...

Details

Author
jamditis
Repository
jamditis/claude-skills-journalism
Created
5 months ago
Last Updated
today
Language
HTML
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category

Testing & QA Listed

test-first-bugfix

Test-driven bug fixing — reproduce before you fix. Use this skill whenever the user reports a bug, describes unexpected behavior, says something is broken, mentions a regression, or asks you to fix an error. This includes phrases like "this is broken", "X doesn't work", "there's a bug in", "getting an error when", "it used to work but now", "failing on", or any variation. Even if the user says "just fix it" or "quick fix", use this skill — the reproduce-first discipline catches regressions and proves the fix actually works. Do NOT skip this skill just because the bug seems obvious or simple.

1 Updated today
The-Artificer-of-Ciphers-LLC
AI & Automation Listed

ae-test-first-fix

Use when fixing a reproducible bug or regression in existing code. First reproduce or define the failure, then add or locate a test, implement the minimum fix, and rerun targeted checks.

0 Updated 4 days ago
deaglecodes
Data & Documents Listed

bugfix

Fix bugs using Test-Driven Development. Use for bug fixes from Linear tickets or user reports. Emphasizes writing tests FIRST before any implementation.

11 Updated today
ConfabulousDev
AI & Automation Listed

bug-fix

Bug fix workflow. Use when: fixing bugs, resolving issues, regression fixes. Not for: new features (use feature-dev), understanding code (use code-explore). Output: fix + regression test + review gate.

1 Updated yesterday
hmj1026
Web & Frontend Listed

fix-bug

Guide for fixing bugs in ClaudeBar following Chicago School TDD and rich domain design. Use this skill when: (1) User reports a bug or unexpected behavior (2) Fixing a defect in existing functionality (3) User asks "fix this bug" or "this doesn't work correctly" (4) Correcting behavior that violates the user's mental model

4 Updated today
kiminmonaco