Stubs, Mocks, Fakes, Dummy
What is the difference between a Stub, a Fake, and a Dummy? Well, as a refresher from Gerard Meszaros’s Test Double Patterns and Martin Fowler’s Mocks Aren’t Stubs: Mock – Sets expectations on how it is used by the sut Stub – Provides canned responses Fake – Has a real, but light-weight ‘shortcut’ implementation Spy – Records information about … Read more