DEV Community

Discussion on: Test First Development at different test stages

Collapse
 
mrlarson2007 profile image
Michael Larson

Uncle Bob, one of the biggest promoters of Test Driven Developement, wrote up a really good blog post about the problems you encountered here: blog.cleancoder.com/uncle-bob/2017...

The point people miss with TDD you need to do some kind of upfront design, then use the tests and code to validate your assuptions. You also need to design your tests to avoid all the extra work of reworking your tests when you refactor something. Using an interface or api layer between your code and tests allows for refacroring the code and not have to constantly rewrite tests. Also important to keep the tests just as clean as the production code.