Pavithra Navaneeth
10/30/2022, 10:52 PMMatt (pactflow.io / pact-js / pact-go)
Hello Team, I have a generic question w.r.t pact consumer. Does pact support letting the consumer to generate the pact json file by hitting the real provider service instead of hitting the provider using pact mock server ?Pact doesn’t no. It’s best thinking of Pact as a unit testing tool. Whilst you could definitely use a record/replay style tool to capture the requests, what you will lose out on is what fields in the response the consumer actually uses - this is an important part of the contract test. Usually, you only use a subset of them. Assuming you need the full suite, means that it will be harder for the provider to evolve. But, you might like to try it as a starting point, and then manually pare the tests back
Matt (pactflow.io / pact-js / pact-go)
Pavithra Navaneeth
10/31/2022, 12:51 AMTimothy Jones
10/31/2022, 12:52 AMDoes pact support letting the consumer to generate the pact json file by hitting the real provider service instead of hitting the provider using pact mock server ?The point of pact is that you don't have to do this, but you get the same value as if you had.
Pavithra Navaneeth
10/31/2022, 3:23 AMMatt (pactflow.io / pact-js / pact-go)
Matt (pactflow.io / pact-js / pact-go)
Pavithra Navaneeth
10/31/2022, 4:18 AMTimothy Jones
10/31/2022, 4:30 AMPavithra Navaneeth
10/31/2022, 4:51 AMTimothy Jones
10/31/2022, 5:57 AM