I\'ve been trying to push my mentallity when developing at home to be geared more towards TDD and a bit DDD.
One thing I don\'t understand though is why you would creat
I upvoted Giraffe's answer, but want to add just a couple of points:
Each developer can use a mock/fake repository for her/his own unit testing without interfering with the tests being done by other developers on the same project.
Using a local mock/fake repository reinforces the user of a data abstraction layer, which is good design practice.
As an example, I've used something as simple as a HashMap
to implement a mock of the data access layer. This makes it extremely easy for each unit test to ensure that exactly the necessary conditions exist for its purpose, and to verify that the right calls were made on the data access layer.