def test_session_from_call(self):
     expected = "an halibut"
     client = HttpClient()
     client.enable_cookies()
     client.delete("http://nothing-to.see/here", proxies=expected)
     spy = self.session_spy.attribute_spies["send"]
     args, kwargs = spy.call_history[-1]
     expect(kwargs).to(contain_key_with_value("proxies", expected))
Beispiel #2
0
 def test_prepares_request_with_given_method(self):
     client = HttpClient()
     client.enable_cookies()
     client.delete("http://vikings")
     expect(self.extract_request_to_prep().method).to(equal("DELETE"))