3 ms·
Yes but then the tests would formally describe the requirements - i.e.they would be a de-facto implementation. Congratulations, you just coded an (indirect) so
by virgilp 6y ago
Yes but then the tests would formally describe the requirements - i.e.they would be a de-facto implementation. Congratulations, you just coded an (indirect) solution to your problem (a solution that you postulate is correct/bug-free)
- tonyhb 6y agoAre you saying this like it's a bad thing? Tests describing requirements acts as documentation, validation, and regression prevention with future refactors.
- virgilp 6y agoMy beef is with the assumption that tests can fully encode the requirements - to the point where any bug would trigger a test failure. Having such a test suite is no simpler than having a perfect implementation of the requirements - i.e. it's probably only feasible, at all, in the simplest/ "didactic" cases. Having a perfect implementation is not bad, of course. It's just not realistic.