MCPcopy Create free account
hub / github.com/ashvardanian/StringZilla / test_translations_random

Function test_translations_random

scripts/test_stringzilla.py:955–959  ·  view source on GitHub ↗
(length: int, seed_value: int)

Source from the content-addressed store, hash-verified

953@pytest.mark.skipif(not numpy_available, reason="NumPy is not installed")
954@pytest.mark.parametrize("seed_value", SEED_VALUES)
955def test_translations_random(length: int, seed_value: int):
956 seed_random_generators(seed_value)
957 body = get_random_string(length=length)
958 lut = np.random.randint(0, 256, size=256, dtype=np.uint8)
959 assert sz.translate(body, memoryview(lut)) == baseline_translate(body, lut)
960
961
962@pytest.mark.parametrize("seed_value", SEED_VALUES)

Callers

nothing calls this directly

Calls 3

baseline_translateFunction · 0.85
seed_random_generatorsFunction · 0.70
get_random_stringFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…