Am I correct in that generating the provider-side contract in PactFlow is limited to the following two options?
1. Upload OpenAPI (OAS), which contains only schema information and decoupled examples of possible inputs and outputs?
2. Running the Consumer's pact against a running instance of the Provider (and therefore all of its dependencies as well).
m
Matt (pactflow.io / pact-js / pact-go)
09/02/2023, 12:32 AM
Yes that's about right.
In both cases it still needs a consumer contract, albeit with bidirectional contract testing this can be generated from mocks/usage (i.e. need not be from hand crafted pact tests). It does need to reflect reality, so http interception is a valid strategy
e
Eytan Hanig
09/02/2023, 11:04 PM
Any recommendations for doing http interception using Python?
m
Matt (pactflow.io / pact-js / pact-go)
09/03/2023, 4:13 AM
Well, interception should be language agnostic (you're intercepting network level requests).
If you use a mocking framework, you could export those mocks to file (e.g. mountebank).
I don't know python well though, so likely there are many good options