Hacker News new | past | comments | ask | show | jobs | submit login

Nobody cares about your precious units they care that the system works. Thus you should test units that are as large as possible. That way if you add a feature you know the old ones didn't break. I've seen too many bugs where all the unit tests passed. If you are doing TDD 1000 integration test failures are no problem - the last thing you changed broke them all: either undo or fix it.

the only reason to write a unit test is if the integration test would run too long.




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

Search: