2 ms·
Multiple-step unit tests are easier to modify to only slightly change the behavior, which is usually too hard to do with property-based testing where small chan
by crabbone 1y ago
Multiple-step unit tests are easier to modify to only slightly change the behavior, which is usually too hard to do with property-based testing where small changes to initial input cause huge changes downstream.
But, in general, yes, unit test failure with many steps would've been just as difficult to interpret.
My experience though was that once such a difficult failure is encountered during property-based testing, one has to write a unit test to reproduce the error anyways. But it's hard to assess the probability of the unexpected behavior of being an actual bug. Sometimes you discover that the system behavior was underspecified, or that you misunderstood how the system is supposed to behave after reading the specification.