pact-net
pact-net copied to clipboard
[GH-505]: Include VerificationExecutionResult when verification fails
As per https://github.com/pact-foundation/pact-net/issues/505 we want to be able to distinguish tehcnical failures from simply not honouring the contract.
This PR throws a more specific exception which allows the caller to determine what has happened.
Merging into the 4.x release branch rather than master - if not, would need to revisit JSON serialization side of things
So I think for now we should just throw the more specific exception rather than try to deserialise all the verification results. They'll also be printed to the console, and it's a big UX change to alter that.
This would also need to target 5.x because it's a breaking API change now that we're throwing a different exception type (albeit a sub type).
Superceded by https://github.com/pact-foundation/pact-net/commit/0199f010c82551c018d3b56bc903aefaf6212750