MCPcopy
hub / github.com/urllib3/urllib3 / test_memory_usage_single_chunk

Method test_memory_usage_single_chunk

test/test_response.py:150–156  ·  view source on GitHub ↗
(
        self, get_func: typing.Callable[[BytesQueueBuffer], bytes]
    )

Source from the content-addressed store, hash-verified

148 )
149 @pytest.mark.limit_memory("10.01 MB", current_thread_only=True)
150 def test_memory_usage_single_chunk(
151 self, get_func: typing.Callable[[BytesQueueBuffer], bytes]
152 ) -> None:
153 buffer = BytesQueueBuffer()
154 chunk = bytes(10 * 2**20) # 10 MiB
155 buffer.put(chunk)
156 assert get_func(buffer) is chunk
157
158 @pytest.mark.parametrize(
159 "finish_with_get_all",

Callers

nothing calls this directly

Calls 2

putMethod · 0.95
BytesQueueBufferClass · 0.90

Tested by

no test coverage detected