message: adding test to check map coordinates
diff: @@ -182,6 +182,53 @@ class RoadCorridorTests(unittest.TestCase):
  self.assertTrue(road_corridor.lane_corridors[1].polygon.Valid())
  self.assertTrue(road_corridor.polygon.Valid())
  + def test_dr_deu_merging_centered(self):
  + # threeway_intersection
  + xodr_parser = XodrParser(os.path.join(os.path.dirname(
  + __file__), "../../../runtime/tests/data/DR_DEU_Merging_MT_v01_centered.xodr"))
  +
  + # World Definition
  + params = ParameterServer()
  + world = World(params)
  +
  + map_interface = MapInterface()
  + map_interface.SetOpenDriveMap(xodr_parser.map)
  + world.SetMap(map_interface)
  +
  + roads = [0, 1]
  + driving_direction = XodrDrivingDirection.forward
  + map_interface.GenerateRoadCorridor(roads, driving_direction)
  + road_corridor = map_interface.GetRoadCorridor(roads, driving_direction)
  +
  + # Draw map
  + viewer = MPViewer(params=params, use_world_bounds=True)
  + viewer.drawWorld(world)
  +
  + viewer.drawPolygon2d(
  + road_corridor.lane_corridors[0].polygon, color="blue", alpha=0.5)
  + viewer.drawPolygon2d(
  + road_corridor.lane_corridors[1].polygon, color="blue", alpha=0.5)
  + viewer.show(block=False)
  +
  + self.assertTrue(road_corridor.lane_corridors[0].polygon.Valid())
  + self.assertTrue(road_corridor.lane_corridors[1].polygon.Valid())
  + self.assertTrue(road_corridor.polygon.Valid())
  +
  + tol = 0.2
  + center_line_array = road_corridor.lane_corridors[0].center_line.ToArray()
  + left_boundary_array = road_corridor.lane_corridors[0].left_boundary.ToArray()
  + right_boundary_array = road_corridor.lane_corridors[0].right_boundary.ToArray()
  +
  + # beginning of left lane
  + self.assertAlmostEquals(center_line_array[0, 0], 106.4, 1)
  + self.assertAlmostEquals(center_line_array[0, 1], 103.47, 1)
  + self.assertAlmostEquals(Distance(Point2d(left_boundary_array[0, 0], left_boundary_array[0, 1]), Point2d(right_boundary_array[0, 0], right_boundary_array[0, 1])), 2.8, 1)
  +
  + # end of left lane
  + self.assertAlmostEquals(center_line_array[-1, 0], -18.15, 1)
  + self.assertAlmostEquals(center_line_array[-1, 1], 109.0, 1)
  + self.assertAlmostEquals(Distance(Point2d(left_boundary_array[-1, 0], left_boundary_array[-1, 1]), Point2d(right_boundary_array[-1, 0], right_boundary_array[-1, 1])), 2.63, 1)
  +
  def test_dr_chn_merging(self):
  # threeway_intersection
  xodr_parser = XodrParser(os.path.join(os.path.dirname(
  