Some tests feel like writing the answer on the back of a card, flipping it over, and celebrating because it says exactly what you expected.
Sure, the test passes.
But when itβs time to release, does that test actually give you confidence?
Stop mocking the code you should be testing.
Real ViewModel. Real dependencies. Real mapping.
Mock only the external boundary.
Full article:
https://medium.com/@alejandrogelos/stop-mocking-the-code-you-should-be-testing-9b2b2533742d
Are you writing tests just to decorate your coverage, or tests that actually add value?
Top comments (0)