Hacker News new | ask | show | jobs
by jdlshore 1203 days ago
> TDD, which assumes how an API is going to be used, without actually writing the actual thing that's going to use it.

That’s not TDD. It’s a common misconception that you’ve fallen for, and are now spreading further.

TDD is a series of small steps where you write a bit of test code—about five lines—and then a bit of production code—about five lines—then refactor, then repeat.

Here’s a free chapter in my book that describes how it works:

https://www.jamesshore.com/v2/books/aoad2/test-driven_develo...

Here’s a video that demonstrates it:

https://www.jamesshore.com/v2/projects/lunch-and-learn/incre...