4 ms·
i'd never seen this quickcheck thing before... it's basically fuzzing built into unit tests, neat... it is, however, quite different from a type checker though
by a-dub 5y ago
i'd never seen this quickcheck thing before... it's basically fuzzing built into unit tests, neat...
it is, however, quite different from a type checker though. where a fuzz tester generates random inputs to try and break a function... a type checker enforces assertions on data that is actually flowing through the system.
i think my big beef with this library is that it does so probabilistically, while marketing itself as something that does complete checks and has been highly optimized. it's not a fast assertion checker, it is one that employs random sampling... that's fine, but it should be extremely upfront about that as this misunderstanding has the potential to cause a lot of pain on top of already painful situations.
- eru 5y agoYes, calling this a typechecker is perhaps a bit euphemistic. Btw, if you want to try something like QuickCheck, Python's Hypothesis is perhaps the most accessible implementation of the idea.