Sha256: 9d29f32a46e18b66f10b79b79b67ab88a4e455822cf2c9dc5dee97fb98f474fa
Contents?: true
Size: 997 Bytes
Versions: 3
Compression:
Stored size: 997 Bytes
Contents
require 'pact_broker/client/pacticipants/create' module PactBroker module Client module Pacticipants2 describe Create do describe ".call" do before do allow_any_instance_of(PactBroker::Client::Hal::HttpClient).to receive(:sleep) end let(:pact_broker_client_options) { {} } let(:broker_base_url) { "http://url" } let(:params) { { name: 'Foo' } } subject { Create.call(params, broker_base_url, pact_broker_client_options)} context "when there is an http error" do let!(:index_request) do stub_request(:get, broker_base_url).to_return(status: 500, body: 'some error', headers: { "Content-Type" => "application/hal+json" } ) end it "returns a failure result" do expect(subject.success).to be false expect(subject.message).to include 'some error' end end end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems