2022-03-31 07:31:15 -06:00
|
|
|
from pathlib import Path
|
|
|
|
|
|
2022-03-12 09:50:16 -07:00
|
|
|
import pytest
|
|
|
|
|
|
2023-08-17 08:27:49 -06:00
|
|
|
import modules.map.lib
|
2022-03-12 09:50:16 -07:00
|
|
|
from modules.map import models
|
|
|
|
|
|
|
|
|
|
|
2022-11-05 14:38:33 -06:00
|
|
|
@pytest.mark.parametrize('size,expected', [
|
|
|
|
|
(0, 0),
|
|
|
|
|
(-1, 0),
|
2023-08-17 08:27:49 -06:00
|
|
|
(17737381, 252),
|
|
|
|
|
(63434267, 904),
|
|
|
|
|
(87745484, 1251),
|
|
|
|
|
(136372996, 1944),
|
|
|
|
|
(116318111, 1658),
|
2022-03-12 09:50:16 -07:00
|
|
|
])
|
2022-11-05 14:38:33 -06:00
|
|
|
def test_seconds_to_import_rpi4(size, expected):
|
2023-08-17 08:27:49 -06:00
|
|
|
assert modules.map.lib.seconds_to_import(size) == expected
|