DiUS / pact-consumer-swift

A Swift / ObjeciveC DSL for creating pacts.
MIT License
98 stars 43 forks source link

Add support for publishing verification results with a branch using the pact-ruby-standalone #127

Closed bethesque closed 2 years ago

bethesque commented 2 years ago

The Pact Broker now supports branches as first class entities. You can read more about this here: https://github.com/pact-foundation/docs.pact.io/blob/feat/deployments-and-releases/website/blog/2021-07-04-why-we-are-getting-rid-of-tags.md

To allow users to use this feature:

surpher commented 2 years ago

This will fit into Scheme setup in Xcode under Post-actions. Before running pact-mock-service stop one should set up the CLI command (or as part of a script) for the --provider-version-branch and pass the branch most likely defined as an env var.

PactConsumerSwift will most likely not expose such an interface due to the way Xcode handles tests and we can not (or at least easily) control pact-ruby-standalone during test runs.

bethesque commented 2 years ago

So, are you saying people can use it already, because they're using the standalone directly?

surpher commented 2 years ago

Not sure if users are using it already. But what pact-consumer-swift does is only handling the consumer side of Pact by making 4 distinct network requests to DELETE, PUT, GET and POST on /, /interactions, /interactions/verification and /pact (in whatever combination it needs to be). Managing the mock server is done through scripts.

That's all that it does. Everything else is scripting outside of pact-consumer-swift. And no provider verification support through this framework.

bethesque commented 2 years ago

Oh, of course. Consumer only. I'll close this.