The three laws of test driven development

Law 1:
You may not write production code until you have written a failing unit test.

Law 2:
You may not write more of a unit test than is sufficient to fail, and not compiling is failing.

Law 3:
You may not write more production code than is sufficient to pass the currently failing test.

Do you hold up to this?

Professionalism and Test-Driven Development, Robert C. Martin, Object Mentor, IEEE Software, May/June 2007 (Vol. 24, No. 3) pp. 32–36
http://doi.ieeecomputersociety.org/10.1109/MS.2007.85

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*