Sha256: 10d37efad6d5f50c6df993ab9fa31846776e5fac3a156cd65e4bbe263daf8074

Contents?: true

Size: 521 Bytes

Versions: 29

Compression:

Stored size: 521 Bytes

Contents

require 'spec_helper'
require 'support/shared_examples_for_request'

module Pact
  describe Consumer::Request::Actual do
    it_behaves_like "a request"

    let(:raw_request) do
      {
        'method' => 'get',
        'path' => '/mallory'
      }
    end

    describe "from_hash" do
      context "when field are not defined" do
        subject { described_class.from_hash(raw_request) }
        it "raises an error" do
          expect{subject}.to raise_error KeyError
        end
      end
    end      
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
pact-1.0.39 spec/lib/pact/consumer/request_spec.rb
pact-1.1.0.rc2 spec/lib/pact/consumer/request_spec.rb
pact-1.0.38 spec/lib/pact/consumer/request_spec.rb
pact-1.1.0.rc1 spec/lib/pact/consumer/request_spec.rb
pact-1.0.37 spec/lib/pact/consumer/request_spec.rb
pact-1.0.36 spec/lib/pact/consumer/request_spec.rb
pact-1.0.35 spec/lib/pact/consumer/request_spec.rb
pact-1.0.34 spec/lib/pact/consumer/request_spec.rb
pact-1.0.33 spec/lib/pact/consumer/request_spec.rb
pact-1.0.32 spec/lib/pact/consumer/request_spec.rb
pact-1.0.31 spec/lib/pact/consumer/request_spec.rb
pact-1.0.30 spec/lib/pact/consumer/request_spec.rb
pact-1.0.29 spec/lib/pact/consumer/request_spec.rb
pact-1.0.28 spec/lib/pact/consumer/request_spec.rb
pact-1.0.27 spec/lib/pact/consumer/request_spec.rb
pact-1.0.26 spec/lib/pact/consumer/request_spec.rb
pact-1.0.25 spec/lib/pact/consumer/request_spec.rb
pact-1.0.24 spec/lib/pact/consumer/request_spec.rb
pact-1.0.23 spec/lib/pact/consumer/request_spec.rb
pact-1.0.22 spec/lib/pact/consumer/request_spec.rb