MCPcopy
hub / github.com/urllib3/urllib3 / test_retry_read_zero

Method test_retry_read_zero

test/test_retry.py:117–123  ·  view source on GitHub ↗

No second chances on read timeouts, by default

(self)

Source from the content-addressed store, hash-verified

115 assert e.value.reason == other_error
116
117 def test_retry_read_zero(self) -> None:
118 """No second chances on read timeouts, by default"""
119 error = ReadTimeoutError(DUMMY_POOL, "/", "read timed out")
120 retry = Retry(read=0)
121 with pytest.raises(MaxRetryError) as e:
122 retry.increment(method="GET", error=error)
123 assert e.value.reason == error
124
125 def test_status_counter(self) -> None:
126 resp = HTTPResponse(status=400)

Callers

nothing calls this directly

Calls 3

incrementMethod · 0.95
ReadTimeoutErrorClass · 0.90
RetryClass · 0.90

Tested by

no test coverage detected