MCPcopy
hub / github.com/openai/openai-python / mock_handler

Method mock_handler

tests/test_client.py:788–790  ·  view source on GitHub ↗
(request: httpx.Request)

Source from the content-addressed store, hash-verified

786 iterator = _make_sync_iterator([file_content], counter=counter)
787
788 def mock_handler(request: httpx.Request) -> httpx.Response:
789 assert counter.value == 0, "the request body should not have been read"
790 return httpx.Response(200, content=request.read())
791
792 with OpenAI(
793 base_url=base_url,

Callers

nothing calls this directly

Calls 1

readMethod · 0.45

Tested by

no test coverage detected