Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test__xy_north_of_limit(lat):
x, y = mercantile._xy(0.0, lat)
assert x == 0.5
assert y < 0
def test__xy_south_of_limit(lat):
x, y = mercantile._xy(0.0, lat)
assert x == 0.5
assert y > 1
def test__xy_limits(lat, fy):
x, y = mercantile._xy(0.0, lat)
assert x == 0.5
assert y == pytest.approx(fy)
def test__xy_poles(lat):
with pytest.raises(mercantile.InvalidLatitudeError):
mercantile._xy(0.0, lat)