Sha256: cc18f117fe62f899475808d3b3943b00cd5d60b1a4e3e7bd12e5f6de0a6d1172
Contents?: true
Size: 694 Bytes
Versions: 48
Compression:
Stored size: 694 Bytes
Contents
shared_context "precedence of stubs" do |*adapter_info| describe "when choosing a matching request stub" do it "should use the last declared matching request stub" do stub_request(:get, "www.example.com").to_return(:body => "abc") stub_request(:get, "www.example.com").to_return(:body => "def") http_request(:get, "http://www.example.com/").body.should == "def" end it "should not be affected by the type of uri or request method" do stub_request(:get, "www.example.com").to_return(:body => "abc") stub_request(:any, /.*example.*/).to_return(:body => "def") http_request(:get, "http://www.example.com/").body.should == "def" end end end
Version data entries
48 entries across 48 versions & 4 rubygems