본문으로 건너뛰기
cccskills
무료GitHub에 공개

tdd-review

Use when completing a TDD step and wanting a quality check. Reviews test quality after RED, implementation correctness after GREEN, and scenario completeness after REFACTOR.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md4.9 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

TDD Review

Step-aware quality review at TDD phase boundaries. Fires when a sub-checkbox is marked in test-definitions.md during implement phase.

Detect Step

Read the gate message to determine which TDD step is next:

Gate triggeredStep just completedReview focus
tdd:greenRED (test written)Review test quality
tdd:refactorGREEN (implementation passes)Review implementation
tdd:redREFACTOR (cleanup done)Review completed scenario

GREEN Gate (RED just completed — review test)

Focused review (~1 minute). Check the test that was just written:

  • Atomic? Tests ONE behavior. Red flag: multiple When/Then pairs.
  • Right assertions? Meaningful expectations, not .toBeTruthy() or .not.toThrow().
  • Behavior, not implementation? Tests observable outcomes. Red flag: mocking internals, checking call counts.
  • Fails for the right reason? Missing behavior, not syntax errors.
  • Right test type? Load the testing skill and consult its scope hierarchy (E2E > Integration > Unit). Was a higher-scope test practical here? Did we drop to unit when integration would catch more?
  • Coverage adequacy? Consult testing guide's bug detection matrix. Ask: "What could still break that this test wouldn't catch?" Flag gaps — missing edge cases, error paths, or boundary values — as candidates for additional scenarios.

If issues found: fix before implementing. If clean: commit and proceed to implementation.

REFACTOR Gate (GREEN just completed — review implementation)

Moderate review (~1-2 minutes). Check the implementation:

  • Minimal? Only code the test requires. No anticipatory design.
  • Correct? Does it actually satisfy the test's intent, not just make it pass by coincidence?
  • No regressions? Full test suite still passes.
  • Run /refactor for structural cleanup.

If issues found: fix before refactoring. If clean: run /refactor, commit, proceed.

RED Gate (REFACTOR just completed — review completed scenario)

Full review (~2-3 minutes). The entire scenario is done. Review the complete unit:

  • Test + implementation alignment? Does the test cover the scenario's Given/When/Then?
  • Run /quality-review for ecosystem verification (versions, deprecated APIs, security).
  • Ready for next scenario? Any loose ends or technical debt to note?

If issues found: address before starting next scenario. If clean: commit and proceed to next [ ] RED.

Concrete example (GREEN gate)

Context: Agent just wrote a failing test for scenario 2 (verbose shows passing files). The tdd:green gate fires.

Agent review:

Atomic? Yes — tests one behavior (passing files appear in verbose output). Right assertions? expect(output).toContain('src/index.ts: pass') — asserts on observable output, not internals. Good. Behavior, not implementation? Yes — checks CLI output string, not internal formatter state. Fails for the right reason? Expected string to contain 'src/index.ts: pass' — verbose output doesn't include passing files yet. Correct failure. Right test type? Integration — needs real linter execution to produce output. Unit wouldn't cover the formatter→CLI pipeline. Correct scope. Coverage gaps? Test only checks one file. Could miss edge case where zero files pass. Acceptable for now — boundary cases are in scenario 3.

Clean.

Next: implement minimum code in packages/cli/src/lint.ts to make expect(output).toContain('src/index.ts: pass') pass, then commit.

Output discipline

Every review ends with a Next: line on its own line — imperative, name the file/command/scenario. Don't end with "proceed" or "commit and move on" alone; name what to do.

  • GREEN gate clean → **Next:** implement minimum code in {file} to make this test pass.
  • GREEN gate issues → **Next:** rewrite assertion in {file}:{line} to check observable output, then re-review.
  • REFACTOR gate clean → **Next:** run /refactor on {file}, then commit and mark next [ ] RED.
  • RED gate clean → **Next:** commit, then start scenario {N} — write the failing test in {file}.

A review without a Next: line is incomplete.

Reminders

  1. Depth matches step — lightweight for GREEN, moderate for REFACTOR, full for RED
  2. Single source of truth — this skill owns all TDD review content
  3. Commit clears the gate — review, then commit to proceed
  4. Mark sub-checkbox — ensure the current step's [x] is marked in test-definitions.md

Voice: plainspoken and concise — write to be scanned.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

audit

무료

Run comprehensive code audit for architecture, dead code, and test quality. Use when reviewing overall codebase health, checking for architectural violations, or before marking a feature complete.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

bdd

무료

Behavior-first feature development — use when building new capabilities, continuing feature work, or when work introduces new state or multiple user flows. Discovers desired behavior through examples and scenarios before implementation. Do NOT use for bug fixes, typos, or small isolated changes.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

Use when the user wants to explore options, weigh approaches, or think through uncertainty before committing to a direction. Collaborative brainstorming and rubber ducking — divergence-first thinking partner.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

Kill zombie dev servers and test processes. Use when ports are blocked, processes are hanging, or test runners won't start.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

debug

무료

Root cause debugging before fixes. Use when investigating bugs, diagnosing test failures, troubleshooting unexpected behavior, or when previous fix attempts failed. Enforces investigate-first discipline.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

elicit

무료

Extract tacit knowledge through non-obvious microquestions — things only the user knows that can't be found in code, docs, or research. Use when you're about to guess at intent, context, or constraints during SAFEWORD's understanding flow. Also use when user says 'ask me', 'what do you need to know', or when another skill (bdd, brainstorm, debug) needs user context before proceeding. Do NOT use for questions answerable by reading the codebase or searching the web.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

TheMostlyGreat/mythos192026년 6월 14일 업데이트

TheMostlyGreat의 스킬 모두 보기

이 스킬의 문제 신고