1
votes

I am using Pact JS for contract testing. I have written both the provider and consumer part and uploaded them to the pact broker. Contracts URLs are pointing to my QA environment. I want to create a Slack webhook that would run on a daily basis and verify that the contract still passes. Is there a way for me to run pact verification on demand without uploading new contracts? Why would I need to change my contracts if I just want to check if nothing changed? this seems like it's a basic functionality everyone should be using, but for the love of me I am unable to find it in the docs

1

1 Answers

0
votes

I think you've misunderstood how the pact broker works. It doesn't run provider tests - your CI job for the provider would run that test, and during that stage it will pull the contracts down from the broker and test against your provider (usually locally, but in your case against a QA env).

So in your case, the thing you want to trigger is the provider CI build, not pact broker.

But also, if nothing is changed (i.e. neither the consumer has published a new contract nor provider has changed its implementation) why run a build at all?