[TIP] Stubbing out httplib2.Http.request

Seth Buntin seth.buntin at gmail.com
Tue Jul 12 11:42:52 PDT 2011


I am having one heck of a time stubbing out Http.request from httplib2. I currently have five test cases and it takes 13 seconds, even though my return_value of Http.request is correct for some reason it seems that the request function is still running.

Here is the gist of my test code:

https://gist.github.com/5ba6bac1d4efd5cb903b

I'm using Michael Foord's mock library. Can anyone help me with this or point me in the right direction? 
-- 
Seth

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.idyll.org/pipermail/testing-in-python/attachments/20110712/674e8d1b/attachment.htm>


More information about the testing-in-python mailing list