Shine Planner Tdd Checkpoints
Shine Planner TDD Checkpoints streamline the TDD process with structured checkpoints and integration guidelines.
Checkpoint Types
checkpoint:human-verify (90% of checkpoints) Human confirms Claude's automated work works correctly.
Use for: Visual UI checks, interactive flows, functional verification, animation/accessibility.
<task type="checkpoint:human-verify" gate="blocking">
<what-built>[What Claude automated]</what-built>
<how-to-verify>
[Exact steps to test - URLs, commands, expected behavior]
</how-to-verify>
<resume-signal>Type "approved" or describe issues</resume-signal>
</task>
checkpoint:decision (9% of checkpoints) Human makes implementation choice affecting direction.
Use for: Technology selection, architecture decisions, design choices.
<task type="checkpoint:decision" gate="blocking">
<decision>[What's being decided]</decision>
<context>[Why this matters]</context>
<options>
<option id="option-a">
<name>[Name]</name>
<pros>[Benefits]</pros>
<cons>[Tradeoffs]</cons>
</option>
</options>
<resume-signal>Select: option-a, option-b, or ...</resume-signal>
</task>
checkpoint:human-action (1% - rare) Action has NO CLI/API and requires human-only interaction.
Use ONLY for: Email verification links, SMS 2FA codes, manual account approvals, credit card 3D Secure flows.
Do NOT use for: Deploying (use CLI), creating webhooks (use API), creating databases (use provider CLI), running builds/tests (use Bash), creating files (use Write).
Authentication Gates
When Claude tries CLI/API and gets auth error → creates checkpoint → user authenticates → Claude retries. Auth gates are created dynamically, NOT pre-planned.
Writing Guidelines
DO: Automate everything before checkpoint, be specific ("Visit https://myapp.vercel.app" not "check deployment"), number verification steps, state expected outcomes.
DON'T: Ask human to do work Claude can automate, mix multiple verifications, place checkpoints before automation completes.
Anti-Patterns
Bad - Asking human to automate:
<task type="checkpoint:human-action">
<action>Deploy to Vercel</action>
<instructions>Visit vercel.com, import repo, click deploy...</instructions>
</task>
Why bad: Vercel has a CLI. Claude should run vercel --yes.
Bad - Too many checkpoints:
<task type="auto">Create schema</task>
<task type="checkpoint:human-verify">Check schema</task>
<task type="auto">Create API</task>
<task type="checkpoint:human-verify">Check API</task>
Why bad: Verification fatigue. Combine into one checkpoint at end.
Good - Single verification checkpoint:
<task type="auto">Create schema</task>
<task type="auto">Create API</task>
<task type="auto">Create UI</task>
<task type="checkpoint:human-verify">
<what-built>Complete auth flow (schema + API + UI)</what-built>
<how-to-verify>Test full flow: register, login, access protected page</how-to-verify>
</task>
</checkpoints>
<tdd_integration>
TDD Plan Structure
TDD candidates identified in task_breakdown get dedicated plans (type: tdd). One feature per TDD plan.
---
phase: XX-name
plan: NN
type: tdd
---
<objective>
[What feature and why]
Purpose: [Design benefit of TDD for this feature]
Output: [Working, tested feature]
</objective>
<feature>
<name>[Feature name]</name>
<files>[source file, test file]</files>
<behavior>
[Expected behavior in testable terms]
Cases: input -> expected output
</behavior>
<implementation>[How to implement once tests pass]</implementation>
</feature>
Red-Green-Refactor Cycle
RED: Create test file → write test describing expected behavior → run test (MUST fail) → commit: test({phase}-{plan}): add failing test for [feature]
GREEN: Write minimal code to pass → run test (MUST pass) → commit: feat({phase}-{plan}): implement [feature]
REFACTOR (if needed): Clean up → run tests (MUST pass) → commit: refactor({phase}-{plan}): clean up [feature]
Each TDD plan produces 2-3 atomic commits.
Context Budget for TDD
TDD plans target ~40% context (lower than standard 50%). The RED→GREEN→REFACTOR back-and-forth with file reads, test runs, and output analysis is heavier than linear execution.
</tdd_integration>