test-driven-development

Enforce a test-first Red-Green-Refactor workflow for features, bug fixes, and refactors.

33|5|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/LowyShin/giip-dev-agent --skill test-driven-development-lowyshin
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: test-driven-development
Source: https://github.com/LowyShin/giip-dev-agent/tree/main/.agent/skills/test-driven-development
Command: npx skills add https://github.com/LowyShin/giip-dev-agent --skill test-driven-development-lowyshin

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Ensures code correctness by enforcing a tests-first approach that minimizes regressions and speeds debugging through immediate feedback.

Core Features & Use Cases

  • Red-Green-Refactor workflow to drive development
  • Encourages writing real tests before production code, avoiding mocks as substitutes
  • Applies to features, bug fixes, and refactors across projects to improve reliability

Quick Start

Write a failing test first, then implement the minimal code to pass it and repeat.

Frequently Asked Questions about test-driven-development

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I start writing tests before code using the Red-Green-Refactor cycle?

To start test-driven development, write a failing test first, implement the minimal code required to pass it, and then refactor while keeping tests green. This enforces a strict test-first workflow to prevent unverified production changes.

What is the best way to write unit tests for bug fixes without relying on mocks?

The best way to fix bugs with unit testing is to write real failing tests that verify behavior before changing code. Avoid using mocks as substitutes, relying instead on real tests to ensure correctness and speed up debugging through immediate feedback.

Does test-driven development work for refactoring existing features across different languages?

Test-driven development applies to refactoring across languages and stacks. You can enforce a tests-first workflow on existing features by writing real tests to verify behavior, ensuring minimal regressions when modifying code.

Why should I use a test-first workflow instead of writing tests after implementation?

A test-first workflow ensures code correctness by providing immediate feedback and minimizing regressions. By relying on real tests rather than mocks, you speed up debugging and prevent unverified production changes from entering your stack.

When should I not use mocks for behavior verification in unit testing?

You should avoid mocks when behavior verification is critical to correctness. Relying on real tests rather than mocks as substitutes ensures your test-driven development cycle accurately verifies software quality across features and refactors.