Skip to content
Back to skills

Tdd

ASecurity

Test-driven development. Write tests FIRST, then implement. Use for core logic, state machines, data transformations.

  • 2 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added September 2, 2026
ai-agents

Security analysis

A100/100

Scanned September 2, 2026

npx -y skills add imoonkey/yaco --skill tdd --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Tdd?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Tdd
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/imoonkey-tdd/badge)](https://www.skillsdirectory.com/skills/imoonkey-tdd)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: tdd
description: Test-driven development. Write tests FIRST, then implement. Use for core logic, state machines, data transformations.
---

# TDD

Write tests before implementation, using the project's test framework. RED (failing test) -> GREEN (minimal code to pass) -> REFACTOR (improve, keep green).

## When to Use

| Use for | Skip for |
|---------|----------|
| State machines, orchestration | UI/browser automation (use e2e) |
| Data transformations, parsing | Simple CRUD / glue code |
| Protocol implementations | One-off scripts |
| Pure utility functions | |

## Cycle

1. Define the interface and result types first.
2. **RED** — write a failing test, run it targeted at the unit under development, confirm it fails.
3. **GREEN** — minimal code to pass.
4. **REFACTOR** — improve, keep green.

## Judgment

Tests are not equal in value — a test that mocks away the logic it claims to cover proves nothing. Aim for robustness, not a coverage number; test observable behavior, not implementation. Where a part doesn't fit TDD, don't force it.

Floor for core logic: ~80% coverage — run a coverage report and check against it.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…