| name | implement-feature-tdd |
| description | Use this workflow to implement ANY new feature following Test-Driven Development strictly. |
Workflow Steps
- Write failing E2E tests FIRST (RED):
- Write E2E test for API boundaries (Controller/Resolver) using
/add-e2e-test skill.
- Run
npm run test:e2e to verify it FAILS.
- Write unit tests (RED):
- Use the
/add-tests skill to write failing unit tests for the Services and Resolvers/Controllers.
- Run
npm run test to verify they FAIL.
- Write implementation (GREEN):
- Implement the minimum code required in the Controller/Resolver and Service to make both E2E and unit tests pass.
- Run tests until they PASS.
- Refactor and Check (REFACTOR):
- Run
npm run check to fix linting and types.
- Run
npm run test:cov to ensure test coverage remains above 80%.
Do not write production code before writing the test assertions.