Sha256: 635fb3ee6cd2effdc13c74b9f12bc8749d69d74fca429a9bf03db77688fa7fd1
Contents?: true
Size: 928 Bytes
Versions: 1
Compression:
Stored size: 928 Bytes
Contents
require 'spec_helper' require 'spec/support/provider_state_builder' require 'pact_broker/api/representors/representable_pact' module PactBroker::Api::Representors describe RepresentablePact do let(:pact) { ProviderStateBuilder.new.create_pact_with_hierarchy 'Consumer', '1.2.3', 'Provider' } subject { RepresentablePact.new(pact) } describe "initialize" do it "creates an object with a provider with a name" do expect(subject.provider.name).to eq 'Provider' end it "creates an object with a provider with a nil version" do expect(subject.provider.version).to be_nil end it "creates an object with a consumer with a name" do expect(subject.consumer.name).to eq 'Consumer' end it "creates an object with a consumer that has the current pact's version" do expect(subject.consumer.version.number).to eq '1.2.3' end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pact_broker-0.0.5 | spec/lib/pact_broker/api/representors/representable_pact_spec.rb |