spec/lib/connection_spec.rb in flexirest-1.3.1 vs spec/lib/connection_spec.rb in flexirest-1.3.2

- old
+ new

@@ -43,12 +43,12 @@ result = @connection.post("/foo", "body") expect(result.body).to eq("{result:true}") end it "should pass a DELETE request through to Faraday" do - stub_request(:delete, "www.example.com/foo").to_return(body: "{result:true}") - result = @connection.delete("/foo") + stub_request(:delete, "www.example.com/foo").with(body: "body").to_return(body: "{result:true}") + result = @connection.delete("/foo", "body") expect(result.body).to eq("{result:true}") end describe "with default Faraday headers" do before do @@ -100,10 +100,10 @@ it "should pass a DELETE request through to Faraday" do stub_request(:delete, "www.example.com/foo"). with(:headers => @default_headers). to_return(body: "{result:true}") - result = @connection.delete("/foo") + result = @connection.delete("/foo", "body") expect(result.body).to eq("{result:true}") end end context 'with custom timeouts' do