public void TestChromosomeClone() { // Use the Assert class to test conditions var chromosome = new LevelChunkChromosome(10); Assert.AreEqual(chromosome, chromosome.Clone()); }
public void TestEquality() { var fitness = new LevelChunkFitness(0); // Use the Assert class to test conditions var chromosome = new LevelChunkChromosome(10); Assert.LessOrEqual(Mathf.Abs((float)fitness.Evaluate(chromosome) - (float)fitness.Evaluate(chromosome.Clone())), _errorMargin); }