3 ms·
Is that a benefit of end-to-end tests? Seems more like encouraging more unit tests would discourage bad coding habits if anything.
by contravariant 6y ago
Is that a benefit of end-to-end tests? Seems more like encouraging more unit tests would discourage bad coding habits if anything.
- pydry 6y agoI don't find it does discourage bad coding habits. It just amplifies the problems they cause.
- contravariant 6y agoWell I suppose any form of discouragement is pointless if it is not recognised and acted upon.
- nullsense 6y agoAs always in these discussions I like to remind everyone that you can have good and bad implementations of everything, and just doing unit testing doesn't make your engineers suddenly understand how to write testable code. So, you can well end up in a situation with a reasonable amount of code coverage, but not quite as high as you might like and when someone invariably digs into why they find while parts of the system are testable, parts of the system aren't. Now you're left with a large test suite that provides marginal value because it doesn't give you confidence your code can be deployed if just because it's passing, but the shite engineering practices heavily test implementation details which make maintenance slow to a crawl. Good engineering is what creates good engineering. What you actually do, I suspect matters a lot less.
- contravariant 6y agoYeah there's no silver bullet for any of these problems probably. That said an end-to-end test seems just as likely to merely test implementation details. You could have all kinds of changes in behaviour without necessarily doing anything incorrect. I suppose the point is that you need to test where you can define what correct behaviour is. And if this is only possible for end-to-end tests then something is screwy.