Skip to content

Commit

Permalink
feat: support app_version_branch in MessageProviderDSL
Browse files Browse the repository at this point in the history
fixes #259
  • Loading branch information
YOU54F committed Aug 6, 2024
1 parent d512570 commit 1653128
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions lib/pact/provider/configuration/message_provider_dsl.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ def app_version_tags tags
self.tags = tags
end

def app_version_branch branch
self.branch = branch
end

def publish_verification_results publish_verification_results
self.publish_verification_results = publish_verification_results
Pact::RSpec.with_rspec_2 do
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,14 +151,15 @@ module Configuration
subject do
described_class.build "some-provider" do
app {}
app_version_branch 'main'
app_version_tags ["dev"]
honours_pacts_from_pact_broker do
end
end
end

it "builds a PactVerificationFromBroker" do
expect(PactVerificationFromBroker).to receive(:build).with("some-provider", nil, ["dev"])
expect(PactVerificationFromBroker).to receive(:build).with("some-provider", 'main', ["dev"])
subject
end
end
Expand Down

0 comments on commit 1653128

Please sign in to comment.