The slides of my talk "Mockist vs. Classicists TDD" at the Softwerkskammer Berlin Meetup http://www.meetup.com/de-DE/Software-Craftsmanship-Berlin/events/227959647/.
Abstract:
There are two different schools of TDD: the proponents of "London School TDD" ("Mockists") drive their design "outside-in" top-down starting with end-to-end acceptance tests. They focus on the interaction between objects, isolate them with interfaces between them and mock them out in their tests. On the contrary the advocates of "Detroit School TDD" ("Classicists") work bottom-up and try to avoid mocks if possible.
In a live coding session I will demonstrate both approaches and discuss their strengths and weaknesses with you.
8. Mockists
● „London School“:
Steve Freeman, Nat Pryce
J.B. Rainsberger
● XP 2000 paper
„Endo-Testing: Unit Testing with Mock Objects “
● OOPSLA 2004 „Mock Roles, not Objects“
● Book „Growing Object Oriented Software“
#GOOS 2009
9. Mockists
● Problem
too many integrated tests
=> break dependencies to test in isolation
● Interfaces & Mocks
● behaviour verification on non-leaf objects,
“Back Door Testing“
● Outside-In Design
18. Classicists
● “Detroit School“: Kent Beck, Uncle Bob, …
more integrated testing
● “front door testing“ & “state verification“
● Only mock at the process boundary
● 3rd Party Systems
● Own DB?
● Design emerges bottom-up/inside-out
(mostly)