mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-29 03:16:22 -05:00
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:
parent
6a22090e54
commit
c815aa68c6
10 changed files with 46 additions and 59 deletions
16
modules/map/test/test_models.py
Normal file
16
modules/map/test/test_models.py
Normal 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
|
||||
Loading…
Add table
Add a link
Reference in a new issue