@Test
public final void testMakeLaneChanges() {

    RoadSegment.resetNextId();
    Vehicle.resetNextId();
    final int laneCount = 2;
    final RoadSegment r0 = new RoadSegment(1000.0, laneCount);
    // set up an obstacle directly in front of a vehicle, so the vehicle will change lanes
    // Obstacle(pos, lane, length, width, color) {
    final Vehicle obstacle = newObstacle(600.0, Lanes.LANE1);
    r0.addVehicle(obstacle);
    final Vehicle v0 = newVehicle(593.0, 5.0, Lanes.LANE1);
    final LaneChangeModel lcm = newLaneChangeModel(v0);
    v0.setLaneChangeModel(lcm);
    r0.addVehicle(v0);
    final double dt = 0.25;
    final double simulationTime = 0.0;
    final long iterationCount = 0;
    r0.makeLaneChanges(dt, simulationTime, iterationCount);
    assertEquals(Lanes.LANE1, obstacle.lane());
    assertEquals(Lanes.LANE2, v0.lane());
    assertEquals(1, r0.laneSegment(Lanes.LANE1).vehicleCount());
    assertEquals(1, r0.laneSegment(Lanes.LANE2).vehicleCount());
}