Chris Williams
05/09/2022, 10:03 AMYousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
⢠A consumer would test against a success (200) and failure (401) against a login endpointThey would setup a provider mock to return 200 or 401 for a specific test case, and generate a Pact contract from a successful match
Yousaf Nabi (pactflow.io)
⢠How a provider would test thoseWith any functional testing tool, we do not mandate the providers choice here, the provider should test any endpoints they expose in an openAPI spec, to provide strong confidence that the implemented service, matches the documented specification. This evidence is uploaded to Pactflow when publishing the provider spec, and forms the provider contract. The bi-directional check, will ensure that the pact contracts generated by the client form a subset of the providers contract, but this check is static, so does not exercise the real provider
Yousaf Nabi (pactflow.io)
Chris Williams
05/09/2022, 10:28 AM200
and 401
state, and it's in the generated OpenAPI, and my consumer has mocked a 200
and 401
, then the BDCT will marry those two up and give it a green light ?Chris Williams
05/09/2022, 10:29 AMYousaf Nabi (pactflow.io)
Chris Williams
05/09/2022, 10:33 AMYousaf Nabi (pactflow.io)
Chris Williams
05/09/2022, 10:34 AMChris Williams
05/09/2022, 10:34 AMYousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
Chris Williams
05/09/2022, 10:35 AMChris Williams
05/09/2022, 10:35 AMChris Williams
05/09/2022, 10:35 AMChris Williams
05/09/2022, 10:36 AMYousaf Nabi (pactflow.io)
Chris Williams
05/09/2022, 10:39 AMYousaf Nabi (pactflow.io)
true/false
https://docs.pactflow.io/docs/bi-directional-contract-testing/contracts/oas#request-details
ā¢verificationResults.content
⢠The base64 encoded test results, which may be any output of your choosing (see base64 encoding below).
ā¢verificationResults.contentType
⢠The content type of the results. Must be a valid mime type
Chris Williams
05/09/2022, 11:00 AMverificationResults.content
can be literally anything - and it's just rendered in pactflow - gottchaYousaf Nabi (pactflow.io)