- Timestamp:
- 07/26/13 14:06:27 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Tests/HeuristicLab-3.3/DeepCloneableCloningTest.cs
r9764 r9783 42 42 } 43 43 44 private TestContext testContextInstance; 45 public TestContext TestContext { 46 get { return testContextInstance; } 47 set { testContextInstance = value; } 48 } 49 44 50 public DeepCloneableCloningTest() { 45 51 excludedTypes = new HashSet<Type>(); … … 55 61 } 56 62 57 private TestContext testContextInstance;58 63 private readonly HashSet<Type> excludedTypes; 59 64 60 /// <summary>61 ///Gets or sets the test context which provides62 ///information about and functionality for the current test run.63 ///</summary>64 public TestContext TestContext {65 get {66 return testContextInstance;67 }68 set {69 testContextInstance = value;70 }71 }72 73 #region Additional test attributes74 //75 // You can use the following additional attributes as you write your tests:76 //77 // Use ClassInitialize to run code before running the first test in the class78 // [ClassInitialize()]79 // public static void MyClassInitialize(TestContext testContext) { }80 //81 // Use ClassCleanup to run code after all tests in a class have run82 // [ClassCleanup()]83 // public static void MyClassCleanup() { }84 //85 // Use TestInitialize to run code before running each test86 // [TestInitialize()]87 // public void MyTestInitialize() { }88 //89 // Use TestCleanup to run code after each test has run90 // [TestCleanup()]91 // public void MyTestCleanup() { }92 //93 #endregion94 95 65 [TestMethod] 66 [TestCategory("General")] 67 [TestCategory("Essential")] 68 [TestProperty("Time", "long")] 96 69 [DeploymentItem(@"HeuristicLab-3.3\Resources\SamplesExperimentFinished.hl")] 97 70 public void TestCloningFinishedExperiment() { … … 105 78 106 79 [TestMethod] 80 [TestCategory("General")] 81 [TestCategory("Essential")] 82 [TestProperty("Time", "long")] 107 83 public void TestCloningAllDeepCloneables() { 108 84 PluginLoader.Assemblies.ToArray(); … … 119 95 try { 120 96 item = (IDeepCloneable)Activator.CreateInstance(deepCloneableType, nonPublic: false); 121 } catch { continue; } // no default constructor 97 } 98 catch { continue; } // no default constructor 122 99 123 100 IDeepCloneable clone = null; 124 101 try { 125 102 clone = (IDeepCloneable)item.Clone(new Cloner()); 126 } catch (Exception e) { 103 } 104 catch (Exception e) { 127 105 TestContext.WriteLine(Environment.NewLine + deepCloneableType.FullName + ":"); 128 106 TestContext.WriteLine("ERROR! " + e.GetType().Name + @" was thrown during cloning.
Note: See TracChangeset
for help on using the changeset viewer.