def test_distance_to_coords_formula_lngwise(self):
""" tests the longitudional (east, west) aspect of the formula to see
if we get waypoints that have the same latitude, different lng """
point_lat = 40.8131494
point_lng = -73.95032520000001
lngwise_potential_waypoints = distance_to_coords_formula(point_lat,
point_lng, 90, 270)
longitude_e = lngwise_potential_waypoints[0][1]
longitude_w = lngwise_potential_waypoints[1][1]
latitude_e = lngwise_potential_waypoints[0][0]
latitude_w = lngwise_potential_waypoints[1][0]
eq_(latitude_e, latitude_w)
eq_(latitude_e, point_lat)
eq_(latitude_w, point_lat)
assert_not_equal(longitude_e, longitude_w)
assert_not_equal(longitude_e, point_lng)
assert_not_equal(longitude_w, point_lng)
评论列表
文章目录