Skip to content

Commit

Permalink
test: pact.provider.branch set pactBroker.providerBranch set - should…
Browse files Browse the repository at this point in the history
… publish branch
  • Loading branch information
YOU54F committed Oct 15, 2024
1 parent db73c5d commit c917af7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,13 @@ test {


// required variables for fetching dynamic pacts, & publishing verification results
// application version to associate with the code being tested, should be unique if contract changes
systemProperty("pact.provider.version", System.getenv("GIT_COMMIT") == null ? "" : System.getenv("GIT_COMMIT"))
// systemProperty("pact.provider.branch", System.getenv("GIT_BRANCH") == null ? "" : System.getenv("GIT_BRANCH"))

// used in consumer version selectors, and fetching pending pacts
systemProperty("pactbroker.providerBranch", System.getenv("GIT_BRANCH") == null ? "" : System.getenv("GIT_BRANCH"))
// used when publishing results with a branch associated with the version
systemProperty("pact.provider.branch", System.getenv("GIT_BRANCH") == null ? "" : System.getenv("GIT_BRANCH"))

// only publish verification results from CI allowing developers to run tests locally and debug, without affecting broker results
// only verification results from a known source (such at a commit in a VCS and a reproducible environment such as CI) should be published
Expand Down

0 comments on commit c917af7

Please sign in to comment.