Calculating time-to-import for map pbf files in the backend. These times were created using a test RPi4. Encoding URL of archive files to prevent error which blocked displaying of archives.

This commit is contained in:
Roland 2022-03-12 09:50:16 -07:00
parent 6a22090e54
commit c815aa68c6
No known key found for this signature in database
GPG key ID: 9D6DBD3ACF11AB93
10 changed files with 46 additions and 59 deletions

View file

@ -0,0 +1,16 @@
import pytest
from modules.map import models
@pytest.mark.parametrize('size,expected', [
(0, 0),
(-1, 0),
(17737381, 4475),
(63434267, 16006),
(87745484, 22141),
(136372996, 34411),
(116318111, 29351),
])
def test_seconds_to_import_rpi4(size, expected):
assert models.seconds_to_import(size) == expected