Created
May 1, 2023 09:31
-
-
Save disegmvm/ca1c3f9e4f684611e4038353fcda3fbb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
publisher := dsl.Publisher{} | |
err := publisher.Publish(types.PublishRequest{ | |
PactURLs: []string{"../client/pacts/sample_consumer-sample_provider.json"}, | |
PactBroker: "https://pen.pactflow.io/", //link to your remote Contract broker | |
BrokerToken: "xxx", //your PactFlow token | |
ConsumerVersion: "1.0.0", | |
Tags: []string{"1.0.0", "latest"}, | |
}) | |
if err != nil { | |
t.Fatal(err) | |
} | |
// Uncomment to verify contract locally | |
/*err := pact.Verify(postCar) | |
if err != nil { | |
t.Fatalf("Error on Verify: %v", err) | |
}*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment