✨ Enforce red/green TDD in DEVELOP prompt (closes #68) - #76
Merged
Conversation
Replaces the soft "write tests" guidance with a non-negotiable red/green/refactor block plus a phase gate blocking GREEN until a failing run is confirmed, addressing the most common skip in agent-driven TDD. Closes #68
7 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Write tests for every new or changed behaviorbullet inDEVELOP_AGENT_PROMPTwith a non-negotiable red/green TDD block (RED, GREEN, REFACTOR), behavioral-assertion rule, and a phase gate forbidding the move from RED to GREEN without a confirmed failing run."I'll write the test after, it's faster".TestDevelopPromptTddContentcovering each new requirement (TDD discipline applied to this change itself — tests written first, confirmed RED, then implementation made them GREEN).Closes #68
Key Flows
flowchart TD A[Agent receives DEVELOP task] --> B[Read planned implementation] B --> C[RED: write failing test] C --> D{test fails for right reason?} D -- no --> C D -- yes --> E[GREEN: minimum code to pass] E --> F{test passes?} F -- no --> E F -- yes --> G[REFACTOR if duplication/naming unclear] G --> H[Commit tests + implementation together]Verification
uv run pytest— passed (123 tests)uv run ruff check— passed (All checks passed!)uv run pyright— passed (0 errors, 0 warnings)