MCPcopy Index your code
hub / github.com/python/cpython / MockHTTPResponse

Class MockHTTPResponse

Lib/test/test_urllib2.py:330–345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328
329
330class MockHTTPResponse(io.IOBase):
331 def __init__(self, fp, msg, status, reason):
332 self.fp = fp
333 self.msg = msg
334 self.status = status
335 self.reason = reason
336 self.code = 200
337
338 def read(self):
339 return ''
340
341 def info(self):
342 return {}
343
344 def geturl(self):
345 return self.url
346
347
348class MockHTTPClass:

Callers 1

getresponseMethod · 0.85

Calls

no outgoing calls

Tested by 1

getresponseMethod · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…