Fork me on GitHub
#test-check
<
2019-12-17
>
jvtrigueros00:12:55

Hi all, I'm debugging a failing test that uses test.check's defspec. When my test fails, I'm able to obtain the seed and I can see the value that caused the test to fail, however, neither the exact value or the reduced value produce the failure. I reckon it's the sequence of values that cause the failure Dx Is there a way that I can output the values so that I can execute them in order and see the failure? The only thing that comes to mind is spiting the values inside the for-all closure.

gfredericks00:12:17

That would work. This isn't a "supported" scenario because it's assumed that your test passes or fails solely based on the generated values

gfredericks00:12:52

So if you don't get your test into that form you'll be fighting the system the whole time

jvtrigueros00:12:20

Right. In this case, I'm doing a roundtrip test with a DynamoDBLocal instance so I bet I'm overwritting something causing failure in the tests.

jvtrigueros00:12:08

Thanks! That helped, I had an issue in my generator.

gfredericks01:12:55

For db stuff, I'd generally look for a way to reset the db at the beginning of each trial, or partition the data so it doesn't overlap