Is there any reason that provider tests automatica...
# pact-broker
s
Is there any reason that provider tests automatically communicate with pact-broker, but consumers just generate json that has to be uploaded manually (or with the CLI)?
m
Yes, because many consumer tests run on a Dev machine and the results are still WIP. So sending to the broker doesn't really make sense. The provider needs to pull from the broker to get the right version (which might be changing)
s
Have you all considered a flag to enable pushing those in those tests? i.e.
pactbroker.uploadContracts
or something? Might be handy so that some cases can avoid the extra contract upload step. I think we're running into an edge case where it's a little painful to get the test output files, so its clumsy to get the json files to upload after the run
m
You could raise a feature request or PR, but at the moment you usually would need the CLI for other steps in your pipeline anyway so I tend to go the CLI route
I could imagine a future world where both sides could be continually connected to a broker to improve the Dev experience but that's not likely to happen any time soon
s
I'll consider submitting one, and yeah definitely not an urgent request. But yeah a world where both sides are connected would be cool -- then the CLI could be run in more independent steps
👍 1