3 ms·
> If you leave the most difficult 20% untested, then you are building a knot of spaghetti code. This is backward. You don’t leave code untested because you’re
by hinkley 7y ago
> If you leave the most difficult 20% untested, then you are building a knot of spaghetti code.
This is backward. You don’t leave code untested because you’re writing spaghetti. You leave it untested because you wrote spaghetti, past tense. If you’re still writing spaghetti then your commits are most likely lowering code coverage, not raising it.
If you’re above 80% and climbing, there’s a good chance that new code is being written at a higher standard. But as the project grows, a new block of code with 98% coverage does less and less to move the needle.
The main exception being the person who can’t seem to realize when they have confused themselves. You know the one. Tries to do everything the hard way and fails because they don’t possess enough surplus clever to do things the hard way.
But they are also the sort that manages to somehow get full coverage without asserting anything important.