We have recently began relying on collection based repositories for functional tests (they store data/objects in memory, instead of saving it in the database). Unit tests should receive mock database connections and return mock data for database calls.
The idea is to split the testing environment into non persistent and persistent. This way you only test the database related bits when you know the code is working properly.
We have recently began relying on collection based repositories for functional tests (they store data/objects in memory, instead of saving it in the database). Unit tests should receive mock database connections and return mock data for database calls.
The idea is to split the testing environment into non persistent and persistent. This way you only test the database related bits when you know the code is working properly.
Yes, agree.