}
@Test
public void test02() {
ScheduledBlockLocation position = _service.getScheduledBlockLocationFromScheduledTime(
_blockConfig, time(10, 02));
assertEquals(_tripA, position.getActiveTrip());
assertEquals(_stopTimeA, position.getClosestStop());
assertEquals(-120, position.getClosestStopTimeOffset());
assertEquals(_stopTimeA, position.getPreviousStop());
assertEquals(_stopTimeB, position.getNextStop());
assertEquals(480, position.getNextStopTimeOffset());
assertEquals(320.0, position.getDistanceAlongBlock(), 0.0);
assertEquals(47.668651, position.getLocation().getLat(), 1e-6);
assertEquals(-122.385467, position.getLocation().getLon(), 1e-6);
assertEquals(2.4, position.getOrientation(), 0.1);
assertEquals(time(10, 02), position.getScheduledTime());
assertTrue(position.isInService());
assertEquals(1, position.getStopTimeIndex());
position = _service.getScheduledBlockLocationFromDistanceAlongBlock(
_blockConfig, 320.0);
assertEquals(_tripA, position.getActiveTrip());
assertEquals(_stopTimeA, position.getClosestStop());
assertEquals(-120, position.getClosestStopTimeOffset());
assertEquals(_stopTimeA, position.getPreviousStop());
assertEquals(_stopTimeB, position.getNextStop());
assertEquals(480, position.getNextStopTimeOffset());
assertEquals(320.0, position.getDistanceAlongBlock(), 0.0);
assertEquals(47.668651, position.getLocation().getLat(), 1e-6);
assertEquals(-122.385467, position.getLocation().getLon(), 1e-6);
assertEquals(2.4, position.getOrientation(), 0.1);
assertEquals(time(10, 02), position.getScheduledTime());
assertTrue(position.isInService());
assertEquals(1, position.getStopTimeIndex());
}