Sha256: 56c1cfccbfac2fc71e910aa3f79ed35eca73912b1c8736cfbacf761f26b1e839

Contents?: true

Size: 1.54 KB

Versions: 39

Compression:

Stored size: 1.54 KB

Contents

require 'pact_broker/client/pact_hash'
require 'pact_broker/client/hal/http_client'

shared_context "pact broker" do
  before do
    allow_any_instance_of(PactBroker::Client::Hal::HttpClient).to receive(:sleep)
    allow_any_instance_of(PactBroker::Client::Hal::HttpClient).to receive(:default_max_tries).and_return(1)
  end
  let(:pact_hash) { PactBroker::Client::PactHash[consumer: {name: 'Condor'}, provider: {name: 'Pricing Service'}, interactions: []] }
  let(:consumer_contract) { Pact::ConsumerContract.from_hash pact_hash }
  let(:pact_json) { pact_hash.to_json }
  let(:pact_broker_client) { PactBroker::Client::PactBrokerClient.new(client_config) }
  let(:broker_base_url) { 'http://localhost:1234' }
  let(:client_config) { { base_url: broker_base_url } }
  let(:consumer_version) { '1.3.0' }
  let(:version) { '1.3.0' }
  let(:pact_broker_version) { Pact::Term.new(:matcher => /\d+\.\d+\.\d+/, :generate => '1.0.0') }
  let(:pact_broker_response_headers) { {'Content-Type' => 'application/hal+json;charset=utf-8'} }
  let(:default_request_headers) { { 'Content-Type' => 'application/json'} }
  let(:old_patch_request_headers)   { { 'Content-Type' => 'application/json'} }
  let(:patch_request_headers)   { { 'Content-Type' => 'application/merge-patch+json'} }
  let(:put_request_headers)     { { 'Content-Type' => 'application/json', 'Accept' => 'application/hal+json'} }
  let(:post_request_headers)    { { 'Content-Type' => 'application/json', 'Accept' => 'application/hal+json'} }
  let(:get_request_headers)     { { 'Accept' => 'application/hal+json'} }
end

Version data entries

39 entries across 39 versions & 1 rubygems

Version Path
pact_broker-client-1.75.3 spec/support/shared_context.rb
pact_broker-client-1.75.1 spec/support/shared_context.rb
pact_broker-client-1.75.0 spec/support/shared_context.rb
pact_broker-client-1.74.0 spec/support/shared_context.rb
pact_broker-client-1.73.0 spec/support/shared_context.rb
pact_broker-client-1.72.0 spec/support/shared_context.rb
pact_broker-client-1.71.0 spec/support/shared_context.rb
pact_broker-client-1.70.0 spec/support/shared_context.rb
pact_broker-client-1.69.0 spec/support/shared_context.rb
pact_broker-client-1.68.0 spec/support/shared_context.rb
pact_broker-client-1.67.0 spec/support/shared_context.rb
pact_broker-client-1.66.1 spec/support/shared_context.rb
pact_broker-client-1.66.0 spec/support/shared_context.rb
pact_broker-client-1.65.0 spec/support/shared_context.rb
pact_broker-client-1.64.0 spec/support/shared_context.rb
pact_broker-client-1.63.0 spec/support/shared_context.rb
pact_broker-client-1.62.1 spec/support/shared_context.rb
pact_broker-client-1.62.0 spec/support/shared_context.rb
pact_broker-client-1.61.1 spec/support/shared_context.rb
pact_broker-client-1.61.0 spec/support/shared_context.rb