@Test
public void testGetNearestPosition() {

	Point1d p;
	p = this.network.getNearestPosition(new Point2d(-5.,0.));
	assertNotNull(p);
	assertSame(this.segment4, p.getSegment());
	assertEpsilonEquals(314.6466271867538, p.getCurvilineCoordinate());
	assertEpsilonEquals(0., p.getLateralDistance());
	p = this.network.getNearestPosition(new Point2d(1000.,1000.));
	assertNotNull(p);
	assertSame(this.segment6, p.getSegment());
	assertEpsilonEquals(304.5784, p.getCurvilineCoordinate());
	assertEpsilonEquals(0., p.getLateralDistance());
	p = this.network.getNearestPosition(new Point2d(1000.,0.));
	assertNotNull(p);
	assertSame(this.segment6, p.getSegment());
	assertEpsilonEquals(304.57839869, p.getCurvilineCoordinate());
	assertEpsilonEquals(0., p.getLateralDistance());
}