MCPcopy Create free account
hub / github.com/anomalyco/opencode-sdk-python / test_client_timeout_option

Method test_client_timeout_option

tests/test_client.py:260–265  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

258 assert timeout == httpx.Timeout(100.0)
259
260 def test_client_timeout_option(self) -> None:
261 client = Opencode(base_url=base_url, _strict_response_validation=True, timeout=httpx.Timeout(0))
262
263 request = client._build_request(FinalRequestOptions(method="get", url="/foo"))
264 timeout = httpx.Timeout(**request.extensions["timeout"]) # type: ignore
265 assert timeout == httpx.Timeout(0)
266
267 def test_http_client_timeout_option(self) -> None:
268 # custom timeout given to the httpx client should be used

Callers

nothing calls this directly

Calls 3

OpencodeClass · 0.90
FinalRequestOptionsClass · 0.90
_build_requestMethod · 0.80

Tested by

no test coverage detected