4 ms·
> Tests increase your confidence that code is correct, and they are much cheaper to do that formal verification, Your confidence as SW engineer. The purpose of
by hulitu 4y ago
> Tests increase your confidence that code is correct, and they are much cheaper to do that formal verification,
Your confidence as SW engineer. The purpose of a test is to look for unexpected behaviour, not for expected behaviour.
- RHSeeger 4y agoAnd to be specific, they generally look for _known_ unexpected behavior; in that you need to have a test for it. Though clearly there's still unknowns, like when you're throwing random data at an api to see if you can find bugs. But even still, you know what _ways_ you're doing that. Tests generally won't turn up things nobody has thought to test.