DEV Community

Alex Pushkarev
Alex Pushkarev

Posted on

Which TDD school is better? 🤔

There're at least two major schools of TDD: 🇬🇧London(outside-in) and Chicago 🇺🇸 (inside-out) and several other schools which considered less influential. Which one is better?

I believe it's none. Let me explain!

Image description

London School of TDD suggests you start with an Acceptance-level test and then go to a lower level testing/implementation. Since inevitably you would be writing code which calls non-existing code you will rely more on mocking and you will need some kind of rough overall general design of a code you're going to write.

Chicago School in contrast suggests starting with the smallest possible requirement and then gradually and incrementally increasing the scope.

Other schools (like twitter-style TDD) could suggest ignoring smaller ("unit") tests entirely.

So which one is better? In fact, it is the wrong way to frame question. The better way would be to ask: Which would make sense to use now?

You see, different schools of TDD has something different to offer in every other case!

Want to know more? Feel free to follow me here and on my YouTube channel: https://www.youtube.com/channel/UCkJRvCK2-l2gCuPT9-HUG7A

Top comments (0)