Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r9190fc76563879702e7b3a30e79ed17f1dbd0985 -ra24a95cb642879d0760c43c44f16c65bc72523ae --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationContextTreeNodeInfoTest.cs) (revision 9190fc76563879702e7b3a30e79ed17f1dbd0985) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationContextTreeNodeInfoTest.cs) (revision a24a95cb642879d0760c43c44f16c65bc72523ae) @@ -951,7 +951,7 @@ } [Test] - public void GivenSuccessfulCalculation_WhenCalculatingFromContextMenu_ThenOutputSetLogMessagesAddedAndUpdateObserver() + public void GivenCalculationThatSucceeds_WhenCalculatingFromContextMenu_ThenOutputSetLogMessagesAddedAndUpdateObserver() { // Given var mainWindow = mocks.Stub(); @@ -977,11 +977,9 @@ } }); - var initialOutput = new TestStructuresOutput(); var parent = new CalculationGroup(); var calculation = new TestClosingStructuresCalculation { - Output = initialOutput, InputParameters = { HydraulicBoundaryLocation = hydraulicBoundaryLocation @@ -1027,7 +1025,7 @@ Assert.AreEqual($"Uitvoeren van berekening '{calculation.Name}' is gelukt.", msgs[6]); }); - Assert.AreNotSame(initialOutput, calculation.Output); + Assert.IsNotNull(calculation.Output); } } } Index: Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r739159886ce078f3fa01b26f0127f8ddf653cdaf -ra24a95cb642879d0760c43c44f16c65bc72523ae --- Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs) (revision 739159886ce078f3fa01b26f0127f8ddf653cdaf) +++ Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs) (revision a24a95cb642879d0760c43c44f16c65bc72523ae) @@ -66,21 +66,6 @@ private GrassCoverErosionInwardsPlugin plugin; private TreeNodeInfo info; - public override void Setup() - { - mocks = new MockRepository(); - plugin = new GrassCoverErosionInwardsPlugin(); - info = plugin.GetTreeNodeInfos().First(tni => tni.TagType == typeof(GrassCoverErosionInwardsCalculationContext)); - } - - public override void TearDown() - { - plugin.Dispose(); - mocks.VerifyAll(); - - base.TearDown(); - } - [Test] public void Initialized_Always_ExpectedPropertiesSet() { @@ -203,6 +188,7 @@ // Call info.ContextMenuStrip(nodeData, null, treeViewControl); } + // Assert // Assert expectancies called in TearDown() } @@ -865,13 +851,9 @@ } }); - var initialOutput = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(double.NaN), - new TestDikeHeightOutput(double.NaN), - new TestOvertoppingRateOutput(double.NaN)); var parent = new CalculationGroup(); var calculation = new GrassCoverErosionInwardsCalculation { - Output = initialOutput, InputParameters = { HydraulicBoundaryLocation = hydraulicBoundaryLocation, @@ -920,7 +902,7 @@ Assert.AreEqual($"Uitvoeren van berekening '{calculation.Name}' is gelukt.", msgs[6]); }); - Assert.AreNotSame(initialOutput, calculation.Output); + Assert.IsNotNull(calculation.Output); } } } @@ -1117,6 +1099,21 @@ Assert.IsNull(result.Calculation); } + public override void Setup() + { + mocks = new MockRepository(); + plugin = new GrassCoverErosionInwardsPlugin(); + info = plugin.GetTreeNodeInfos().First(tni => tni.TagType == typeof(GrassCoverErosionInwardsCalculationContext)); + } + + public override void TearDown() + { + plugin.Dispose(); + mocks.VerifyAll(); + + base.TearDown(); + } + private static void ChangeDikeProfile(DikeProfile dikeProfile) { dikeProfile.CopyProperties(new DikeProfile(dikeProfile.WorldReferencePoint, Index: Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r33ce6fa967e380d4c68bd5f53acc189ab7f1e726 -ra24a95cb642879d0760c43c44f16c65bc72523ae --- Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationContextTreeNodeInfoTest.cs) (revision 33ce6fa967e380d4c68bd5f53acc189ab7f1e726) +++ Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationContextTreeNodeInfoTest.cs) (revision a24a95cb642879d0760c43c44f16c65bc72523ae) @@ -1132,11 +1132,9 @@ } }); - var initialOutput = new TestStructuresOutput(); var parent = new CalculationGroup(); var calculation = new TestHeightStructuresCalculation { - Output = initialOutput, InputParameters = { HydraulicBoundaryLocation = hydraulicBoundaryLocation @@ -1184,7 +1182,7 @@ Assert.AreEqual($"Uitvoeren van berekening '{calculation.Name}' is gelukt.", msgs[6]); }); - Assert.AreNotSame(initialOutput, calculation.Output); + Assert.IsNotNull(calculation.Output); } } } Index: Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Plugin.Test/TreeNodeInfos/StabilityPointStructuresCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r951c6fb790f3ea3e0a89771b62ad323967746455 -ra24a95cb642879d0760c43c44f16c65bc72523ae --- Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Plugin.Test/TreeNodeInfos/StabilityPointStructuresCalculationContextTreeNodeInfoTest.cs (.../StabilityPointStructuresCalculationContextTreeNodeInfoTest.cs) (revision 951c6fb790f3ea3e0a89771b62ad323967746455) +++ Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Plugin.Test/TreeNodeInfos/StabilityPointStructuresCalculationContextTreeNodeInfoTest.cs (.../StabilityPointStructuresCalculationContextTreeNodeInfoTest.cs) (revision a24a95cb642879d0760c43c44f16c65bc72523ae) @@ -964,11 +964,9 @@ } }); - var initialStructuresOutput = new TestStructuresOutput(); var parent = new CalculationGroup(); var calculation = new TestStabilityPointStructuresCalculation { - Output = initialStructuresOutput, InputParameters = { HydraulicBoundaryLocation = hydraulicBoundaryLocation, @@ -1019,7 +1017,7 @@ Assert.AreEqual($"Uitvoeren van berekening '{calculation.Name}' is gelukt.", msgs[6]); }); - Assert.AreNotSame(initialStructuresOutput, calculation.Output); + Assert.IsNotNull(calculation.Output); } } }