Repository navigation
Description
Bug Description
/speckit-tasks treats tests as optional even when the project constitution makes test-first development mandatory. The skill says:
Tests are OPTIONAL: Only generate test tasks if explicitly requested in the feature specification or if user requests TDD approach.
templates/tasks-template.md says the same ("Tests are OPTIONAL - only include them if explicitly requested in the feature specification") and labels each story's test section "OPTIONAL - only if tests requested".
The tasks command does load .specify/memory/constitution.md, but this explicit rule wins over it in practice, so a non-negotiable principle such as "a failing test MUST exist before implementation" is ignored. /speckit-analyze and /speckit-converge both treat the constitution as non-negotiable, so the generated tasks.md then fails the project's own analysis. This is not a request for built-in TDD tooling (#2634); it is about /speckit-tasks honouring a principle the constitution already states.
Steps to Reproduce
specify init --here --ai claude(Spec Kit 1.3.2).- Put a test-first principle in
.specify/memory/constitution.md, e.g. "All production code is written test-first. A failing test MUST exist and be observed failing before implementation (NON-NEGOTIABLE)." - Run
/speckit-specifyand/speckit-planfor any feature, without mentioning tests in the request. - Run
/speckit-taskswithout arguments.
Expected Behavior
/speckit-tasks should follow the constitution it already loads and generate a failing-test task before each implementation task when the constitution requires test-first development. Tests stay optional only for projects whose constitution doesn't require them.
Actual Behavior
No test tasks are generated unless the request or spec explicitly asks for them. Users with a test-first constitution have to repeat "test-first" in every /speckit-tasks call, or edit the generated skill and template locally. Those local edits are overwritten on the next specify init or upgrade.
Specify CLI Version
1.3.2
AI Agent
Claude Code
Operating System
macOS 27.2
Python Version
3.15.2
Error Logs
N/A (no error; wrong output)
Additional Context
Still present on main (checked against v1.4.5): templates/commands/tasks.md lines 88, 148, 216 and templates/tasks-template.md lines 12, 83, 109, 131, 157.
Possible fix: in templates/commands/tasks.md, replace the "Tests are OPTIONAL" rule with: "Generate test tasks when the spec or user asks for them, or when the constitution requires test-first development; in that case put a failing-test task before each implementation task." Then drop the "OPTIONAL" wording from templates/tasks-template.md (or make it conditional on the constitution).
AI Disclosure
Drafted with Claude Code (Claude Opus 5.5), human-supervised: the user asked for the report and approved the final text before posting. The issue was found during an AI-assisted audit of the project's agent configuration.


Activity