Changeset 14353 for trunk/sources/HeuristicLab.Tests/HeuristicLab.Encodings.PermutationEncoding-3.3/OrderCrossover2Test.cs
- Timestamp:
- 10/23/16 19:31:18 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Tests/HeuristicLab.Encodings.PermutationEncoding-3.3/OrderCrossover2Test.cs
r14185 r14353 20 20 #endregion 21 21 22 using HeuristicLab.Core; 22 23 using HeuristicLab.Tests; 23 24 using Microsoft.VisualStudio.TestTools.UnitTesting; … … 30 31 [TestClass()] 31 32 public class OrderCrossover2Test { 33 /// <summary> 34 ///A test for Cross 35 ///</summary> 36 [TestMethod] 37 [TestCategory("Encodings.Permutation")] 38 [TestProperty("Time", "short")] 39 public void OrderCrossover2CrossTest() { 40 TestRandom random = new TestRandom(); 41 var privateObject = new PrivateObject(typeof(OrderCrossover2)); 42 random.Reset(); 43 bool exceptionFired = false; 44 try { 45 privateObject.Invoke("Cross", random, new ItemArray<Permutation>(new Permutation[] { 46 new Permutation(PermutationTypes.RelativeUndirected, 4), new Permutation(PermutationTypes.RelativeUndirected, 4), new Permutation(PermutationTypes.RelativeUndirected, 4)})); 47 } 48 catch (System.InvalidOperationException) { 49 exceptionFired = true; 50 } 51 Assert.IsTrue(exceptionFired); 52 } 53 32 54 /// <summary> 33 55 ///A test for Apply
Note: See TracChangeset
for help on using the changeset viewer.