martedì 20 giugno 2017

The Three Laws of Test-Driven Development

The Three Laws of Test-Driven Development - Programmer 97-things:

"There are three simple laws:
  1. You can't write any production code until you have first written a failing unit test. 
  2. You can't write more of a unit test than is sufficient to fail, and not compiling is failing. 
  3. You can't write more production code than is sufficient to pass the currently failing unit test. If
If you follow the three laws every module will be testable by definition. And another word for testable is decoupled. "