Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The theory and the practice of unit tests are often different things. In theory you’ll make changes to the code, and the unit tests will show whether they had the intended effects.

In practice, because often the unit tests are mocking out all the classes they interact with (as is the recommended style for isolated tests) you’ll either have all the tests explode constantly because the interface being mocked has changed, or you’ll have tests that confidently tell you things are working despite the methods they call no longer existing.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: