@Test
public void testDistance() {

  final Line3 line1 = new Line3(Vector3.ZERO, Vector3.UNIT_Z);
  final Vector3 store = new Vector3();
  assertTrue(0.0 == line1.distanceSquared(new Vector3(0, 0, 5), store));
  assertTrue(16.0 == line1.distanceSquared(new Vector3(0, 4, 1), store));
  assertEquals(Vector3.UNIT_Z, store);
  assertTrue(9.0 == line1.distanceSquared(new Vector3(0, -3, -1), store));
  assertEquals(Vector3.NEG_UNIT_Z, store);
  assertTrue(1.0 == line1.distanceSquared(Vector3.NEG_UNIT_X, null));
}