3 ms·
> Unit tests don't help you determine whether a given behavior is incidental or necessary. That's his point. If you have a test-case for the behaviour, you kno
by josteink 10y ago
> Unit tests don't help you determine whether a given behavior is incidental or necessary.
That's his point. If you have a test-case for the behaviour, you know that this is how it should actually behave.
Anything not covered in tests however, that will naturally be covered in uncertainty for any weirdness, quirks or odd behaviour. Should it be there or not? Hard to tell when it's not formalized in a unit-test.
- flukus 10y agoAssuming they were testing behavior and not shooting for some coverage metric. I come across plenty of bugs with tests against them. I have a rather strict rule personally, every test should start with a line that says what it's testing.