TDD Refactor — Testing skill for Claude Code
Refactor code with confidence using comprehensive test safety net.
How to install TDD Refactor
Installs to ~/.claude/commands/thc1006-nephoran-intent-operator-tdd-refactor.md
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/thc1006/nephoran-intent-operator/HEAD/.claude/commands/tdd-refactor.md -o ~/.claude/commands/thc1006-nephoran-intent-operator-tdd-refactor.md Restart Claude Code, or start a new session, for it to be picked up.
What TDD Refactor does
Refactor code with confidence using comprehensive test safety net:
[Extended thinking: This tool uses the tdd-orchestrator agent (opus model) for sophisticated refactoring while maintaining all tests green. It applies design patterns, improves code quality, and optimizes performance with the safety of comprehensive test coverage.]
Usage
Use Task tool with subagent_type="tdd-orchestrator" to perform safe refactoring.
Prompt: "Refactor this code while keeping all tests green: $ARGUM
Alternatives in Testing
- AI Contribution Skills (Engram) — branch-pr: clean branch and PR workflow 2.5k ★
- Claude Codepro — by Max Ritter - Professional development environment for Claude Code with spec-driven workflow, TDD enforcemen 1.6k ★
- Add Scaffold — 按 14-phase 工作流为指定 app 编写清理 scaffold(含需求采集、实测勘测、TOML、safety test、UI 集成) 1.3k ★
Full documentation available on GitHub
View Source RepositoryRelated Skills
Test Driven Development.SKILL
Enforces TDD discipline with RED-GREEN-REFACTOR cycle. Use when writing new features, fixing bugs, or refactor
TDD Cycle
Execute a comprehensive Test-Driven Development (TDD) workflow with strict red-green-refactor discipline:
TDD
by zscott - Guides development using Test-Driven Development principles, enforcing Red-Green-Refactor discipli
Try
Manually test the latest change with one positive and one negative case. Goal is speed — shortest path to conf
Test Dotnet
Run .NET/C# tests for Unity projects and backend services
Red Team
/red-team — Test safety scanning robustness
Related Agents
Dnp TDD Developer Easy
⚡ Fast TDD for routine .NET tasks: clear requirements, low-risk changes, well-defined scope. Writes both tests
TDD Test Author
Writes the RED tests for a .NET/DDD behaviour when /implement-tdd delegates the test-first phase.
Senior Test Engineer
Use to author RED (failing) tests first in the TDD cycle — xUnit + Moq + FluentAssertions for .NET, Vitest + T