Przejdź do treści
Biblioteka skilli
Programowanie · Budowanie i kod

tdd

/tdd

Implementuje kolejny krok zatwierdzonego planu w dwóch commitach: najpierw czerwone testy, potem kod, który je przechodzi.

Repozytorium
pg-toolkit ↗
Licencja
MIT
Ostatnia zmiana repozytorium
06.11.2026

Ocena i bezpieczeństwo

90/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść25 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
1
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 06.11.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Implementuje kolejny krok zatwierdzonego planu w dwóch commitach: najpierw czerwone testy, potem kod, który je przechodzi.

Argumenty

/tdd F-xx [step | finding]
Oryginalny opis (EN)

Implement the next unchecked step of an approved plan, or one review finding marked fix, as a red commit with failing tests and a green commit with the code that passes them; test files are locked during green. Use for all implementation work on a feature or fix branch.

Jak działa

  1. Red
  2. Green
  3. Then
Sekcje z nagłówków SKILL.md, w oryginale · 31 linii, 311 słów
Podgląd SKILL.md
---
name: tdd
description: Implement the next unchecked step of an approved plan, or one review finding marked fix, as a red commit with failing tests and a green commit with the code that passes them; test files are locked during green. Use for all implementation work on a feature or fix branch.
argument-hint: "F-xx [step | finding]"
---

# /pg:tdd F-xx [step | finding]

Delivers one plan step, or one review finding marked `fix`, as a red/green commit pair. The phase lives in `.pg/state/tdd-phase` (not committed); while it says `green`, the plugin's `tdd-guard` hook refuses edits to test files.

## Red

1. Read `plan.md` and pick the step (default: the first without `red` ticked). For a finding, read its row in `review.md`.
2. Confirm you are on the feature branch and the working tree is clean.
3. Run `mkdir -p .pg/state && echo red > .pg/state/tdd-phase`.
4. Write the tests the step names. Follow `docs/standards/testing.md`.
5. Add only the stubs the tests need to load: signatures that throw "not implemented". No logic.
6. Run the new tests. They must fail, and for the reason the step addresses (an assertion or "not implemented"), not because the test itself is broken. Show the failure.
7. Run format, lint and type checks (not the test suite), so the commit is clean.
8. Commit `test(<scope>): <behaviour specified>` with `Refs: F-xx`. Tick `red` in the plan in the same commit.

## Green

1. Run `echo green > .pg/state/tdd-phase`.
2. Write the smallest change that makes the tests pass, following `docs/standards/`. Do not edit tests. If a test is wrong, stop, explain why, and with the human's agreement go back to Red with a separate `test(...)` commit that says what changed.
3. Run the check command from CLAUDE.md. Everything must pass, not only the new tests.
4. Commit `feat(<scope>): ...` (or `fix(<scope>): ...` for a finding or bug) with `Refs: F-xx`. Tick `green` in the plan in the same commit.
5. Optional: a `refactor(<scope>): ...` commit, tests untouched and green.
6. Run `rm -f .pg/state/tdd-phase`.

## Then

- Report: the step, both commit hashes, anything surprising.
- After the last step, suggest `/pg:review F-xx`.
- One step per invocation unless the human asks for more.

Wersje

RepozytoriumWynikLicencja
Ta strona · pg013c/pg-toolkit90MIT
kdlbs/kandev100AGPL-3.0
sentimony/skills100MIT
sentimony/skills100MIT
TerminalSkills/skills100Apache-2.0
duronext/jig100MIT
xoai/sage100MIT
rolemodel/skills100MIT
matteocodogno/wellforge100MIT

Migawka bazy z 13.11.2026 · wersja paczki e432649ea7f4 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100tdd-feature
    Dostarcza szkielet red-green-refactor do budowy nowych funkcji w TDD: najpierw padające testy, potem implementacja, która je przechodzi.
  • 100054-design-tdd
    Prowadzi zmiany w Javie metodą TDD: najpierw test, który nie przechodzi, potem minimalny kod i refaktoryzacja.
  • 100red-green-refactor
    Prowadzi przez cykl TDD red-green-refactor: najpierw test, który pada, potem minimalny kod przechodzący test i refaktoryzacja przy zielonych testach.
  • 100tdd-workflow
    Pomaga zacząć nową funkcję od padających testów, a potem wdrożyć minimalny kod, który je przechodzi (Red, Green, Refactor).
  • 95test-driven-development
    Implementuje funkcję lub poprawkę najpierw przez testy, w krótkich cyklach red-green-cleanup, gdy użytkownik wprost prosi o TDD albo dowody red-green-refactor.
  • 90tdd-guide
    Prowadzi pracę test-first: najpierw nieprzechodzące testy, cykl RED, GREEN, REFACTOR, dla funkcji, błędów i refaktoryzacji zmieniających zachowanie.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.