Skip to content

Commit

Permalink
tests: pact tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
rashiagarwal committed Jun 15, 2018
1 parent 803c025 commit f96adfe
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions spec/service_consumers/provider_states_for_pact_ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,41 @@
end
end

provider_state "consumer-1 and consumer-2 have no pacts with provider provider-1 tagged with tag-1" do
set_up do
TestDataBuilder.new
.create_provider('provider-1')
.create_consumer('consumer-1')
.create_consumer_version('1.3.0')
.create_pact
.create_consumer('consumer-2')
.create_consumer_version('1.4.0')
.create_pact
end
end

provider_state "consumer-1 and consumer-2 have pacts with provider provider-1 tagged with master" do
set_up do
TestDataBuilder.new
.create_provider('provider-1')
.create_consumer('consumer-1')
.create_consumer_version('1.3.0')
.create_consumer_version_tag('master')
.create_pact
.create_consumer('consumer-2')
.create_consumer_version('1.4.0')
.create_consumer_version_tag('master')
.create_pact
end
end

provider_state "consumer-1 has no pacts with provider provider-1 tagged with tag-1" do
set_up do
TestDataBuilder.new
.create_provider('provider-1')
.create_consumer('consumer-1')
.create_consumer_version('1.3.0')
.create_pact
end
end
end

0 comments on commit f96adfe

Please sign in to comment.