hey all, please correct my understanding I have a...
# pact-go
s
hey all, please correct my understanding I have added contract tests for message pacts using pact-go and got the setup done as below 1. Team A’s Message Pact Consumer side test runs using their JSON model for the data and publishes in Jenkins to the host with git version set to consumer version 2. Team B’s Message Pact Provider side test runs in Jenkins using their JSON Model and verifies against the contract from the host. 3. If there is a model change and both teams not in-sync, contract verification will fail and pipeline will fail, so both teams will have to liaise and fix. The pipeline failures have MSTeams alerts. I was thinking the above is enough to identify the dependency issues and solving the purpose. I haven’t incorporated below things, please advise whether these are required. 1. Publishing only when there is a change? 2. Can-i-deploy check? 3. Webhooks to trigger provider pipeline. Thanks.
y
yes to all, its advisable, but with regards to 1, the pact broker will determine if the contents have changed since the last verification and publish an event to trigger a webhook of the pact of that. so you can always publish the pacts from CI, regardless of whether there are changes or not (as that is determined by your broker) you’ll see specific rationale for each concept in the docs.pact.io site
s
thanks @Yousaf Nabi (pactflow.io), will go through that site again to understand rationale, otherwise I take those 3 are advisable and my setup should be fine to carry on.
y
yea you can iteratively add each step into your existing setup.
👍 1