tdd-workflow

Guide Python teams through red-green-refactor cycles with pytest and moto mocking.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/expeor/aws-automation --skill tdd-workflow-expeor
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd-workflow
Source: https://github.com/expeor/aws-automation/tree/main/.claude/skills/tdd-workflow
Command: npx skills add https://github.com/expeor/aws-automation --skill tdd-workflow-expeor

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

TDD 워크플로우 가이드는 테스트 주도 개발의 철학과 실천 방법을 팀이 일관되게 적용하도록 돕습니다. 테스트가 코드 설계와 유지 보수의 주도권을 갖도록 하는 것이 주 목표입니다.

Core Features & Use Cases

  • Red-Green-Refactor 사이클의 실무 가이드와 예시를 제공합니다.
  • pytest와 moto 모킹을 활용한 테스트 작성 패턴 및 베스트 프랙티스를 제시합니다.
  • 테스트 명명 규칙, 작은 단위의 테스트 작성, 점진적 리팩토링에 대한 실용적 권장사항을 포함합니다.

Quick Start

Try applying the TDD workflow to your Python project by writing a failing test first, then implementing the minimal code to pass, and finally refactoring.

Frequently Asked Questions about tdd-workflow

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

FAQPage Schema
How do I implement a red-green-refactor cycle in Python using pytest?

The red-green-refactor cycle in pytest starts by writing a minimal failing test, then implementing the exact code required to pass it, and finally refactoring while keeping tests green. This enforces test-driven design.

What is the best way to mock AWS services in Python integration tests with moto?

Mocking AWS services in Python integration tests with moto involves applying moto decorators to intercept boto3 calls, returning controlled dummy data. This isolates test-driven development workflows from live API costs.

Can I use test-driven development for both unit and integration testing in Python?

Yes, test-driven development applies to both unit and integration testing in Python. The workflow defines small unit tests for logic and broader integration tests with moto mocking to verify component interactions.

How does the red-green-refactor workflow improve software quality?

The red-green-refactor workflow improves software quality by forcing incremental test coverage and immediate feedback. Refactoring only occurs after passing tests, ensuring structural changes never break existing behavior.

What naming conventions should I follow for minimal viable tests in TDD?

Naming conventions for minimal viable tests in TDD should clearly describe the tested behavior and expected outcome. Structuring test names around specific scenarios keeps the test suite readable and maintainable.

Do I need pytest and moto to apply this test-driven development workflow?

Pytest and moto are the primary frameworks targeted by this test-driven development workflow. While the red-green-refactor principles apply universally, the provided patterns and examples are tailored for these specific Python tools.