Changeset 13246 for stable/HeuristicLab.Tests/HeuristicLab.Encodings.PermutationEncoding-3.3/UniformLikeCrossoverTest.cs
- Timestamp:
- 11/18/15 13:01:38 (8 years ago)
- Location:
- stable
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
stable
- Property svn:mergeinfo changed
/trunk/sources merged: 13227,13235-13236
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Tests
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Tests merged: 13227,13235-13236
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Tests/HeuristicLab.Encodings.PermutationEncoding-3.3/UniformLikeCrossoverTest.cs
r12009 r13246 54 54 Assert.IsTrue(Auxiliary.PermutationIsEqualByPosition(expected, actual)); 55 55 } 56 57 /// <summary>58 ///A test for Cross59 ///</summary>60 [TestMethod]61 [TestCategory("Encodings.Permutation")]62 [TestProperty("Time", "short")]63 public void UniformLikeCrossoverCrossTest() {64 UniformLikeCrossover_Accessor target = new UniformLikeCrossover_Accessor();65 IRandom random = new TestRandom(new int[] { }, new double[] { 0.1, 0.2, 0.3, 0.4 });66 random.Reset();67 bool exceptionFired = false;68 try {69 target.Cross(random, new ItemArray<Permutation>(new Permutation[] {70 new Permutation(PermutationTypes.RelativeUndirected, 4), new Permutation(PermutationTypes.RelativeUndirected, 4), new Permutation(PermutationTypes.RelativeUndirected, 4)}));71 } catch (System.InvalidOperationException) {72 exceptionFired = true;73 }74 Assert.IsTrue(exceptionFired);75 }76 56 } 77 57 }
Note: See TracChangeset
for help on using the changeset viewer.