

def test_handle_request_with_retries_all_error(self):
    status_codes = [500, 500, 500, 500, 500]
    internal_proxy.Application = DumbApplicationFactory(status_codes)
    p = internal_proxy.InternalProxy(retries=3)
    req = swob.Request.blank('/')
    orig_req = internal_proxy.swob_request_copy(req)
    resp = p._handle_request(req)
    self.assertEquals(req.path_info, orig_req.path_info)
    self.assertEquals(p.upload_app.call_count, 3)
    self.assertEquals(resp.status_int, 500)

dataset/ETHPy150Open notmyname/slogging/test_slogging/unit/test_internal_proxy.py TestInternalProxy.test_handle_request_with_retries_all_error/original