MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / mock_handler

Method mock_handler

tests/test_client.py:1018–1020  ·  view source on GitHub ↗
(request: httpx2.Request)

Source from the content-addressed store, hash-verified

1016 iterator = _make_sync_iterator([file_content], counter=counter)
1017
1018 def mock_handler(request: httpx2.Request) -> httpx2.Response:
1019 assert counter.value == 0, "the request body should not have been read"
1020 return httpx2.Response(200, content=request.read())
1021
1022 with Anthropic(
1023 base_url=base_url,

Callers

nothing calls this directly

Calls 1

readMethod · 0.45

Tested by

no test coverage detected