Vonage/vonage-dotnet-sdk

Property-Based testing randomly fails

Tr00d opened this issue · 1 comments

Tr00d commented

Describe the bug
UseCase test ShouldReturnFailure_GivenApiErrorCannotBeParsed fails when the generated content is {}

To Reproduce
Steps to reproduce the behavior:
Run the test with the following StdGen: (1012640639,297175377)

Expected behavior
The generator should not generate {}, and the test should always pass.

Additional context
Here's the test ouput:

FsCheck.Xunit.PropertyFailedException

Falsifiable, after 27 tests (0 shrinks) (StdGen (1012640639,297175377)):
Original:
<null>
UpgradeRequired
"{}"

  Exception doesn't have a stacktrace

Xunit.Sdk.XunitException
Expected result to be Failure "426 - Unable to deserialize '{}' into 'ErrorResponse'. - {}.", but found to be Failure '426.'.
Tr00d commented

Fixed in #400