Skip to content

[Extension]: Add TDD Extension #3978

Description

@d0whc3r

Extension ID

tdd

Extension Name

TDD Extension

Version

1.1.2

Description

Drives spec-kit implementation with tests: a language-agnostic red-green-refactor loop with a per-feature test list, recorded red and green evidence, and mutation-checked test strength.

Author

d0whc3r

Repository URL

https://github.com/d0whc3r/spec-kit-tdd

Download URL

https://github.com/d0whc3r/spec-kit-tdd/releases/download/v1.1.2/tdd-1.1.2.zip

License

MIT

Homepage (optional)

https://d0whc3r.github.io/spec-kit-tdd/

Documentation URL (optional)

https://github.com/d0whc3r/spec-kit-tdd/wiki

Changelog URL (optional)

https://github.com/d0whc3r/spec-kit-tdd/blob/main/CHANGELOG.md

Required Spec Kit Version

=0.11.9

Required Tools (optional)

None. This extension is plain Markdown command and template text. It adds no external tool or runtime dependencies beyond Spec Kit itself.

Number of Commands

4

Number of Hooks (optional)

3

Tags

acceptance-tests, mutation-testing, property-based-testing, quality, red-green-refactor, spec-kit, spec-kit-extension, tdd, test-driven-development, test-first, testing, unit-tests

Key Features

  • /speckit.tdd.setup: Detect the repository's test stack and write .specify/memory/tdd-profile.md with the exact verified commands the loop needs (single test, full suite, coverage, mutation), plus the TDD principle to add to the project constitution
  • /speckit.tdd.plan: Derive the feature's test list from spec.md and plan.md into specs//tdd/test-list.md (outer acceptance behaviors, inner unit behaviors, each traced to an acceptance criterion) and make the test tasks in tasks.md mandatory and correctly ordered
  • /speckit.tdd.run: Drive the red-green-refactor loop one behavior at a time from the test list: write one failing test, prove it fails for the right reason, make it pass with the smallest change, refactor while green, record the evidence in the feature's tdd/cycle-log.md, and tick the tasks.md tasks the completed behaviors cover
  • /speckit.tdd.verify: Audit the feature's TDD discipline and test strength from cold context: test-first evidence in git history, red-phase evidence, test-smell rubric, mutation testing on the changed files, and acceptance-criteria coverage, then write specs//tdd/verification.md with a verdict and remediation tasks

Testing Checklist

  • Extension installs successfully via download URL
  • All commands execute without errors
  • Documentation is complete and accurate
  • No security vulnerabilities identified
  • Tested on at least one real project

Submission Requirements

  • Valid extension.yml manifest included
  • README.md with installation and usage instructions
  • LICENSE file included
  • GitHub release created with version tag
  • All command files exist and are properly formatted
  • Extension ID follows naming conventions (lowercase-with-hyphens)

Testing Details

Tested by the https://github.com/d0whc3r/spec-kit-tdd release pipeline (release):

  • Manifest validation (pnpm run validate) confirms extension.yml and catalog.json agree on version, command count, and hook count.
  • Content lint (pnpm run lint:content) enforces the output style rules every command must follow.
  • The release archive tdd-1.1.2.zip is built and attached to the GitHub release at tag v1.1.2.
  • Install is exercised from the published download URL above.

Test project: the committed examples/ artifacts (a test list, a cycle log, and a verification report) come from running the full loop on a real codebase.

Example Usage

# Install the extension from the release archive
specify extension add tdd --from https://github.com/d0whc3r/spec-kit-tdd/releases/download/v1.1.2/tdd-1.1.2.zip

# Once per repository: detect and verify the test stack
/speckit.tdd.setup

# Per feature, after /speckit.tasks: derive the test list
/speckit.tdd.plan

# Drive the red-green-refactor loop, one behavior per cycle
/speckit.tdd.run
/speckit.tdd.run all

# Audit the discipline and the strength of the tests from cold context
/speckit.tdd.verify

Proposed Catalog Entry

{
  "tdd": {
    "name": "TDD Extension",
    "id": "tdd",
    "description": "Drives spec-kit implementation with tests: a language-agnostic red-green-refactor loop with a per-feature test list, recorded red and green evidence, and mutation-checked test strength.",
    "author": "d0whc3r",
    "version": "1.1.2",
    "download_url": "https://github.com/d0whc3r/spec-kit-tdd/releases/download/v1.1.2/tdd-1.1.2.zip",
    "repository": "https://github.com/d0whc3r/spec-kit-tdd",
    "homepage": "https://d0whc3r.github.io/spec-kit-tdd/",
    "documentation": "https://github.com/d0whc3r/spec-kit-tdd/wiki",
    "changelog": "https://github.com/d0whc3r/spec-kit-tdd/blob/main/CHANGELOG.md",
    "license": "MIT",
    "category": "process",
    "effect": "read-write",
    "requires": {
      "speckit_version": ">=0.11.9"
    },
    "provides": {
      "commands": 4,
      "hooks": 3
    },
    "tags": [
      "acceptance-tests",
      "mutation-testing",
      "property-based-testing",
      "quality",
      "red-green-refactor",
      "spec-kit",
      "spec-kit-extension",
      "tdd",
      "test-driven-development",
      "test-first",
      "testing",
      "unit-tests"
    ],
    "created_at": "2026-08-03T00:00:00Z",
    "updated_at": "2026-08-03T19:26:51Z"
  }
}

Additional Context

Full user documentation lives on the project website (https://d0whc3r.github.io/spec-kit-tdd/) and the project wiki, with reference docs at https://github.com/d0whc3r/spec-kit-tdd/wiki. Source repository: https://github.com/d0whc3r/spec-kit-tdd.

A complete, real worked example (a test list, the cycle log with its recorded red output, and the verification report) is committed at https://github.com/d0whc3r/spec-kit-tdd/tree/main/examples so reviewers and users can see exactly what each command reads and writes.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions