MCPcopy Create free account
hub / github.com/dpkp/kafka-python / test_lz4_incremental

Function test_lz4_incremental

test/test_codec.py:108–115  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

106@pytest.mark.skipif(not has_lz4() or platform.python_implementation() == 'PyPy',
107 reason="python-lz4 crashes on old versions of pypy")
108def test_lz4_incremental():
109 for i in range(1000):
110 # lz4 max single block size is 4MB
111 # make sure we test with multiple-blocks
112 b1 = random_string(100).encode('utf-8') * 50000
113 b2 = lz4_decode(lz4_encode(b1))
114 assert len(b1) == len(b2)
115 assert b1 == b2
116
117
118@pytest.mark.skipif(not has_zstd(), reason="Zstd not available")

Callers

nothing calls this directly

Calls 2

random_stringFunction · 0.90
encodeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…