tdd-cycle

Guide Ruby developers through the RED-GREEN-REFACTOR cycle using Minitest and fixtures.

3|Updated Oct 16, 2025
One-click install
npx skills add https://github.com/dchuk/source_monitor --skill tdd-cycle-dchuk
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd-cycle
Source: https://github.com/dchuk/source_monitor/tree/main/.claude/skills/tdd-cycle
Command: npx skills add https://github.com/dchuk/source_monitor --skill tdd-cycle-dchuk

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps developers practice Test-Driven Development in Ruby projects using Minitest and fixtures, guiding teams to write tests first and drive feature implementation with a repeatable cycle.

Core Features & Use Cases

  • Red-Green-Refactor workflow with explicit steps.
  • Fixture-based testing patterns and Rails-friendly conventions.
  • Step-by-step guidance from requirement analysis to refactor, covering model, controller, system, and service tests.
  • Comprehensive workflow checklists and best practices for test structure and helper utilities.

Quick Start

Run the guided TDD workflow: write a failing test, implement only enough code to pass, then refactor and repeat.

Frequently Asked Questions about tdd-cycle

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

FAQPage Schema
How do I practice TDD cycles in Ruby using Minitest?

The TDD cycle in Ruby projects follows Red-Green-Refactor: write a failing Minitest fixture, implement the minimum code to pass, then refactor. This Skill provides step-by-step guidance and workflow checklists for maintaining this repeatable cycle across models, controllers, services, and system tests.

What is the best way to structure Minitest fixtures for Rails feature workflows?

The best way to structure Minitest fixtures for feature workflows is to follow Rails-friendly conventions and helper utilities. This Skill defines the required project file structure, helper patterns, and fixture-based validation to ensure repeatable TDD cycles across models, controllers, services, and system tests.

Does this TDD workflow guidance apply to Ruby service and system tests?

Yes, this TDD workflow guidance applies to Ruby service and system tests. It provides step-by-step guidance from requirement analysis to refactor, specifically covering models, controllers, services, and system tests using Minitest and fixtures.

How do I move from a failing test to refactoring in Ruby Minitest?

To move from a failing test to refactoring in Ruby Minitest, you implement only enough code to make the test pass, then refactor. This Skill outlines explicit Red-Green-Refactor steps and workflow checklists to guide the transition safely while maintaining repeatable test cycles.

What are the limitations of using fixtures for TDD in Ruby projects?

A limitation of using fixtures for TDD in Ruby projects is the need to strictly follow predefined project conventions and file structures. This Skill focuses exclusively on fixture-based validation patterns and does not cover alternative test doubles like mocks or stubs.