- Timestamp:
- 08/20/13 17:03:31 (11 years ago)
- Location:
- stable
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
stable
- Property svn:mergeinfo changed
/trunk/sources merged: 9764-9775,9777-9778,9782-9786,9792,9803,9806-9807,9810
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Tests
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Tests merged: 9764-9775,9777-9778,9782-9786,9792,9803,9806
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Tests/HeuristicLab.Encodings.IntegerVectorEncoding-3.3/Auxiliary.cs
r9456 r9885 20 20 #endregion 21 21 22 using HeuristicLab.Encodings.IntegerVectorEncoding; 23 24 namespace HeuristicLab.Encodings.IntegerVectorEncoding_33.Tests { 22 namespace HeuristicLab.Encodings.IntegerVectorEncoding.Tests { 25 23 public static class Auxiliary { 26 24 public static bool IntegerVectorIsEqualByPosition(IntegerVector p1, IntegerVector p2) { -
stable/HeuristicLab.Tests/HeuristicLab.Encodings.IntegerVectorEncoding-3.3/DiscreteCrossoverTest.cs
r9456 r9885 21 21 22 22 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.IntegerVectorEncoding;24 23 using HeuristicLab.Tests; 25 24 using Microsoft.VisualStudio.TestTools.UnitTesting; 26 25 27 namespace HeuristicLab.Encodings.IntegerVectorEncoding_33.Tests { 28 29 26 namespace HeuristicLab.Encodings.IntegerVectorEncoding.Tests { 30 27 /// <summary> 31 28 ///This is a test class for DiscreteCrossoverTest and is intended … … 34 31 [TestClass()] 35 32 public class DiscreteCrossoverTest { 36 37 38 private TestContext testContextInstance;39 40 /// <summary>41 ///Gets or sets the test context which provides42 ///information about and functionality for the current test run.43 ///</summary>44 public TestContext TestContext {45 get {46 return testContextInstance;47 }48 set {49 testContextInstance = value;50 }51 }52 53 #region Additional test attributes54 //55 //You can use the following additional attributes as you write your tests:56 //57 //Use ClassInitialize to run code before running the first test in the class58 //[ClassInitialize()]59 //public static void MyClassInitialize(TestContext testContext)60 //{61 //}62 //63 //Use ClassCleanup to run code after all tests in a class have run64 //[ClassCleanup()]65 //public static void MyClassCleanup()66 //{67 //}68 //69 //Use TestInitialize to run code before running each test70 //[TestInitialize()]71 //public void MyTestInitialize()72 //{73 //}74 //75 //Use TestCleanup to run code after each test has run76 //[TestCleanup()]77 //public void MyTestCleanup()78 //{79 //}80 //81 #endregion82 83 33 /// <summary> 84 34 ///A test for Cross 85 35 ///</summary> 86 [TestMethod()] 87 [DeploymentItem("HeuristicLab.Encodings.IntegerVectorEncoding-3.3.dll")] 36 [TestMethod] 37 [TestCategory("Encodings.IntegerVector")] 38 [TestProperty("Time", "short")] 88 39 public void DiscreteCrossoverCrossTest() { 89 40 DiscreteCrossover_Accessor target = new DiscreteCrossover_Accessor(new PrivateObject(typeof(DiscreteCrossover))); … … 98 49 IntegerVector actual; 99 50 actual = target.Cross(random, parents); 100 } 101 catch (System.ArgumentException) { 51 } catch (System.ArgumentException) { 102 52 exceptionFired = true; 103 53 } … … 108 58 ///A test for Apply 109 59 ///</summary> 110 [TestMethod()] 60 [TestMethod] 61 [TestCategory("Encodings.IntegerVector")] 62 [TestProperty("Time", "short")] 111 63 public void DiscreteCrossoverApplyTest() { 112 64 TestRandom random = new TestRandom(); … … 130 82 try { 131 83 actual = DiscreteCrossover.Apply(random, new ItemArray<IntegerVector>(new IntegerVector[] { parent1, parent2 })); 132 } 133 catch (System.ArgumentException) { 84 } catch (System.ArgumentException) { 134 85 exceptionFired = true; 135 86 } 136 87 Assert.IsTrue(exceptionFired); 137 88 } 138 139 /// <summary>140 ///A test for DiscreteCrossover Constructor141 ///</summary>142 [TestMethod()]143 public void DiscreteCrossoverConstructorTest() {144 DiscreteCrossover target = new DiscreteCrossover();145 }146 89 } 147 90 } -
stable/HeuristicLab.Tests/HeuristicLab.Encodings.IntegerVectorEncoding-3.3/SinglePointCrossoverTest.cs
r9456 r9885 21 21 22 22 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.IntegerVectorEncoding;24 23 using HeuristicLab.Tests; 25 24 using Microsoft.VisualStudio.TestTools.UnitTesting; 26 25 27 namespace HeuristicLab.Encodings.IntegerVectorEncoding_33.Tests { 28 29 26 namespace HeuristicLab.Encodings.IntegerVectorEncoding.Tests { 30 27 /// <summary> 31 28 ///This is a test class for SinglePointCrossoverTest and is intended … … 34 31 [TestClass()] 35 32 public class SinglePointCrossoverTest { 36 37 38 private TestContext testContextInstance;39 40 /// <summary>41 ///Gets or sets the test context which provides42 ///information about and functionality for the current test run.43 ///</summary>44 public TestContext TestContext {45 get {46 return testContextInstance;47 }48 set {49 testContextInstance = value;50 }51 }52 53 #region Additional test attributes54 //55 //You can use the following additional attributes as you write your tests:56 //57 //Use ClassInitialize to run code before running the first test in the class58 //[ClassInitialize()]59 //public static void MyClassInitialize(TestContext testContext)60 //{61 //}62 //63 //Use ClassCleanup to run code after all tests in a class have run64 //[ClassCleanup()]65 //public static void MyClassCleanup()66 //{67 //}68 //69 //Use TestInitialize to run code before running each test70 //[TestInitialize()]71 //public void MyTestInitialize()72 //{73 //}74 //75 //Use TestCleanup to run code after each test has run76 //[TestCleanup()]77 //public void MyTestCleanup()78 //{79 //}80 //81 #endregion82 83 33 /// <summary> 84 34 ///A test for Cross 85 35 ///</summary> 86 [TestMethod()] 87 [DeploymentItem("HeuristicLab.Encodings.IntegerVectorEncoding-3.3.dll")] 36 [TestMethod] 37 [TestCategory("Encodings.IntegerVector")] 38 [TestProperty("Time", "short")] 88 39 public void SinglePointCrossoverCrossTest() { 89 40 SinglePointCrossover_Accessor target = new SinglePointCrossover_Accessor(new PrivateObject(typeof(SinglePointCrossover))); … … 98 49 IntegerVector actual; 99 50 actual = target.Cross(random, parents); 100 } 101 catch (System.ArgumentException) { 51 } catch (System.ArgumentException) { 102 52 exceptionFired = true; 103 53 } … … 110 60 IntegerVector actual; 111 61 actual = target.Cross(random, parents); 112 } 113 catch (System.ArgumentException) { 62 } catch (System.ArgumentException) { 114 63 exceptionFired = true; 115 64 } … … 120 69 ///A test for Apply 121 70 ///</summary> 122 [TestMethod()] 71 [TestMethod] 72 [TestCategory("Encodings.IntegerVector")] 73 [TestProperty("Time", "short")] 123 74 public void SinglePointCrossoverApplyTest() { 124 75 TestRandom random = new TestRandom(); … … 141 92 try { 142 93 actual = SinglePointCrossover.Apply(random, parent1, parent2); 143 } 144 catch (System.ArgumentException) { 94 } catch (System.ArgumentException) { 145 95 exceptionFired = true; 146 96 } 147 97 Assert.IsTrue(exceptionFired); 148 98 } 149 150 /// <summary>151 ///A test for SinglePointCrossover Constructor152 ///</summary>153 [TestMethod()]154 public void SinglePointCrossoverConstructorTest() {155 SinglePointCrossover target = new SinglePointCrossover();156 }157 99 } 158 100 } -
stable/HeuristicLab.Tests/HeuristicLab.Encodings.IntegerVectorEncoding-3.3/UniformOnePositionManipulatorTest.cs
r9456 r9885 21 21 22 22 using HeuristicLab.Data; 23 using HeuristicLab.Encodings.IntegerVectorEncoding;24 23 using HeuristicLab.Tests; 25 24 using Microsoft.VisualStudio.TestTools.UnitTesting; 26 25 27 namespace HeuristicLab.Encodings.IntegerVectorEncoding _33.Tests {26 namespace HeuristicLab.Encodings.IntegerVectorEncoding.Tests { 28 27 /// <summary> 29 28 ///This is a test class for UniformOnePositionManipulator and is intended … … 32 31 [TestClass()] 33 32 public class UniformOnePositionManipulatorTest { 34 35 36 private TestContext testContextInstance;37 38 /// <summary>39 ///Gets or sets the test context which provides40 ///information about and functionality for the current test run.41 ///</summary>42 public TestContext TestContext {43 get {44 return testContextInstance;45 }46 set {47 testContextInstance = value;48 }49 }50 51 #region Additional test attributes52 //53 //You can use the following additional attributes as you write your tests:54 //55 //Use ClassInitialize to run code before running the first test in the class56 //[ClassInitialize()]57 //public static void MyClassInitialize(TestContext testContext)58 //{59 //}60 //61 //Use ClassCleanup to run code after all tests in a class have run62 //[ClassCleanup()]63 //public static void MyClassCleanup()64 //{65 //}66 //67 //Use TestInitialize to run code before running each test68 //[TestInitialize()]69 //public void MyTestInitialize()70 //{71 //}72 //73 //Use TestCleanup to run code after each test has run74 //[TestCleanup()]75 //public void MyTestCleanup()76 //{77 //}78 //79 #endregion80 81 82 33 /// <summary> 83 34 ///A test for Apply 84 35 ///</summary> 85 36 [TestMethod()] 37 [TestCategory("Encodings.IntegerVector")] 38 [TestProperty("Time", "short")] 86 39 public void UniformOnePositionManipulatorApplyTest() { 87 40 TestRandom random = new TestRandom(); … … 98 51 Assert.IsTrue(Auxiliary.IntegerVectorIsEqualByPosition(expected, parent)); 99 52 } 100 101 /// <summary>102 ///A test for UniformOnePositionManipulator Constructor103 ///</summary>104 [TestMethod()]105 public void UniformOnePositionManipulatorConstructorTest() {106 UniformOnePositionManipulator target = new UniformOnePositionManipulator();107 }108 53 } 109 54 }
Note: See TracChangeset
for help on using the changeset viewer.