Test First By Evidence

Write the test first, watch it fail, then write the least code that passes. Covers where the test belongs, what makes it honest, what a passing test proves and what it does not, recovering when code was written before the test, and starting a bug fix from a red run. A test nobody watched fail proves nothing. Use when implementing a feature or a bugfix, when a test was written after the code, when a test passes the first time you run it, or when the user says "write tests for this", "add coverage", or "TDD this". Not for judging tests inside a change under review, not for choosing a test framework, and not for raising a coverage number, which is the behaviour the honest-test rule exists to refuse.

gabrielmoreira Updated 17 repo stars

File contents

gabrielmoreira/skills/tree/main/skills/test-first-by-evidence commit 1490673f6d

Frequently asked questions

npx skillmds@latest add gabrielmoreira/test-first-by-evidence