4 ms·
Laziness is a kind of populism. Such articles will be always upvoted.
by EugeneOZ 9y ago
Laziness is a kind of populism. Such articles will be always upvoted.
- TallGuyShort 9y agoHe's not preaching laziness, he's against hitting metrics solely for the sake of hitting the metric when the metric is irrelevant. 100% code coverage? Good. 100% code coverage in a single test framework at 10 times the development cost when it's still not really 100%? Stupid. Working smarter isn't always in opposition to working harder.
- EugeneOZ 9y agoNo, he is exactly against covering simple code by tests. It's explained below first sentence. It is funny how things turn around. For fifteen years I have been preaching TDD (Test-driven development, or as it used to be called: test-first approach), or at least for developers to write some unit tests. However, in recent times I have found myself saying more often, "Why did you write that test?" instead of, "You should write a test." Answer to that "funny turn around" sentence is simple - he is getting older and more lazy. Each of us will, each of us should fight with it. And after that, example of what I'm talking about: It seems that he had trouble using Mockito to test the following piece of code: ... I think he was very surprised with my response: "You don't need to test that."
- JoeAltmaier 9y agoA concise word for 'older and lazy' might be 'experienced'
- EugeneOZ 9y agoNot always, not in this case definitely.
- JoeAltmaier 9y agoI don't know; disagreement over whether everything must be tested isn't enough to call it 'lazy'? Its an easy dart to throw. But remember, everything you don't do leaves room for more progress elsewhere. Its an optimization problem.