@Test
public void testNonNaturalFitness()
{
TerminationCondition condition = new TargetFitness(1.0d, false);
PopulationData<Object> data = new PopulationData<Object>(new Object(), 5.0d, 4.0d, 0, true, 2, 0, 0, 100);
assert !condition.shouldTerminate(data) : "Should not terminate before target fitness is reached.";
data = new PopulationData<Object>(new Object(), 1.0d, 3.1d, 0, true, 2, 0, 0, 100);
assert condition.shouldTerminate(data) : "Should terminate once target fitness is reached.";
}
}