advent-of-code/tests/2024/day1/test_part1.py
2024-12-02 16:23:28 +01:00

14 lines
306 B
Python

from pathlib import Path
from day1 import part1
def test_compute_distance():
list1 = [1, 2, 3, 3, 3, 4]
list2 = [3, 3, 3, 4, 5, 9]
assert part1.compute_distance(list1, list2) == 11
def test_main():
test_file = Path(__file__).parent / "test-data"
assert part1.main(test_file) == 11