diff options
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/test_util.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/unit/test_util.py b/tests/unit/test_util.py index b35f218..0ac5c33 100644 --- a/tests/unit/test_util.py +++ b/tests/unit/test_util.py @@ -30,6 +30,11 @@ def test_fix_iso_timestamp(timestamp, fixed): @pytest.mark.parametrize('delta, multiple, expected', [ ( + timedelta(seconds=0), + timedelta(seconds=1), + timedelta(seconds=0), + ), + ( timedelta(minutes=42), timedelta(minutes=15), timedelta(minutes=45), @@ -82,3 +87,12 @@ def test_tour_metadata(gpx_file): @pytest.mark.parametrize('mps, kph', [(1, 3.6), (10, 36)]) def test_mps_to_kph(mps, kph): assert util.mps_to_kph(mps) == pytest.approx(kph, 0.1) + + +def test_tile_url(app_request): + route_url = util.tile_url(app_request, "tile-proxy", provider="bobby") + + assert "{x}" in route_url + assert "{y}" in route_url + assert "{z}" in route_url + assert "bobby" in route_url |