box-o-sand/leetcode/test_roman.py

16 lines
246 B
Python
Raw Normal View History

2023-10-24 19:48:15 +00:00
import pytest
import roman
@pytest.mark.parametrize(
("n", "expected"),
[
(3, "III"),
(58, "LVIII"),
(1994, "MCMXCIV"),
],
)
def test_int_to_roman(n: int, expected: str):
assert roman.i2r(n) == expected