def test_pixels_to_lon_lat_1(self): gmp = GlobalMercatorProfile() point = PixelsPoint(1, 2) try: gmp.to_lon_lat(point) assert False except NotImplementedError as e: assert e is not None and type(e) == NotImplementedError
def test_lon_lat_to_lon_lat_1(self): gmp = GlobalMercatorProfile() point = LonLatPoint(123.4567890, 98.7654321) result = gmp.to_lon_lat(point) assert point.lon == result.lon and \ point.lat == result.lat
def test_meters_to_lon_lat_1(self): gmp = GlobalMercatorProfile() point = MetersPoint(20037508.342789244, 20037508.342789244) result = gmp.to_lon_lat(point) assert result.lon == 180.0 and \ result.lat == 85.0511287798066