diff --git a/src/random_number.py b/src/random_number.py new file mode 100644 index 0000000..5e92e3c --- /dev/null +++ b/src/random_number.py @@ -0,0 +1,4 @@ +from random import randint + +def random_number(min: int, max: int) -> int: + return randint(min, max) diff --git a/tests/test_random_number.py b/tests/test_random_number.py new file mode 100644 index 0000000..f6df5ae --- /dev/null +++ b/tests/test_random_number.py @@ -0,0 +1,5 @@ +from src.random_number import random_number + +def test_random_number() -> None: + t = random_number(0, 100) + assert t >= 0 and t <= 100