pyo3/examples/rustapi_module/tests/test_dict_iter.py
2018-11-13 00:53:06 +09:00

13 lines
251 B
Python

from rustapi_module._test_dict import DictSize
import pytest
@pytest.mark.parametrize(
"size",
[64, 128, 256],
)
def test_size(size):
d = {}
for i in range(size):
d[i] = str(i)
assert DictSize(len(d)).iter_dict(d) == size