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

Method mock_handler

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

Source from the content-addressed store, hash-verified

2454 iterator = _make_async_iterator([file_content], counter=counter)
2455
2456 async def mock_handler(request: httpx2.Request) -> httpx2.Response:
2457 assert counter.value == 0, "the request body should not have been read"
2458 return httpx2.Response(200, content=await request.aread())
2459
2460 async with AsyncAnthropic(
2461 base_url=base_url,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected