mirror of
https://github.com/enzet/map-machine.git
synced 2025-05-31 09:56:24 +02:00
Reformat tests with Black.
This commit is contained in:
parent
5406fc9cf2
commit
c69f1fdae8
3 changed files with 5 additions and 7 deletions
|
@ -24,7 +24,7 @@ def test_gradient() -> None:
|
||||||
"""
|
"""
|
||||||
Test color picking from gradient.
|
Test color picking from gradient.
|
||||||
"""
|
"""
|
||||||
assert (
|
color: Color = get_gradient_color(
|
||||||
get_gradient_color(0.5, MinMax(0, 1), [Color("black"), Color("white")])
|
0.5, MinMax(0, 1), [Color("black"), Color("white")]
|
||||||
== Color("#7F7F7F")
|
|
||||||
)
|
)
|
||||||
|
assert color == Color("#7F7F7F")
|
||||||
|
|
|
@ -3,9 +3,7 @@ Test coordinates computation.
|
||||||
"""
|
"""
|
||||||
import numpy as np
|
import numpy as np
|
||||||
|
|
||||||
from roentgen.flinger import (
|
from roentgen.flinger import osm_zoom_level_to_pixels_per_meter, pseudo_mercator
|
||||||
osm_zoom_level_to_pixels_per_meter, pseudo_mercator
|
|
||||||
)
|
|
||||||
|
|
||||||
__author__ = "Sergey Vartanov"
|
__author__ = "Sergey Vartanov"
|
||||||
__email__ = "me@enzet.ru"
|
__email__ = "me@enzet.ru"
|
||||||
|
|
|
@ -25,7 +25,7 @@ def test_meters() -> None:
|
||||||
check_length("50m", 50.0)
|
check_length("50m", 50.0)
|
||||||
check_length("50.m", 50.0)
|
check_length("50.m", 50.0)
|
||||||
check_length("50.05m", 50.05)
|
check_length("50.05m", 50.05)
|
||||||
check_length(".05m", .05)
|
check_length(".05m", 0.05)
|
||||||
check_length(".m", None)
|
check_length(".m", None)
|
||||||
check_length("50 m", 50.0)
|
check_length("50 m", 50.0)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue