Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/TreeNodeInfos/ClosingStructureFailureMechanismContextTreeNodeInfoTest.cs =================================================================== diff -u -rce5d60b8a5c520faec45cce64de6957dce747449 -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/TreeNodeInfos/ClosingStructureFailureMechanismContextTreeNodeInfoTest.cs (.../ClosingStructureFailureMechanismContextTreeNodeInfoTest.cs) (revision ce5d60b8a5c520faec45cce64de6957dce747449) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/TreeNodeInfos/ClosingStructureFailureMechanismContextTreeNodeInfoTest.cs (.../ClosingStructureFailureMechanismContextTreeNodeInfoTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -610,7 +610,6 @@ InputParameters = { HydraulicBoundaryLocation = new HydraulicBoundaryLocation(-1, "nonExisting", 1, 2), - Structure = new TestClosingStructure() } }); failureMechanism.CalculationsGroup.Children.Add(new TestClosingStructuresCalculation @@ -619,7 +618,6 @@ InputParameters = { HydraulicBoundaryLocation = new HydraulicBoundaryLocation(-1, "nonExisting", 1, 2), - Structure = new TestClosingStructure() } }); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs =================================================================== diff -u -r3f40e34c76b06d66a6426c7e07fb3a101b4952cb -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs (.../ClosingStructuresCalculationServiceTest.cs) (revision 3f40e34c76b06d66a6426c7e07fb3a101b4952cb) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs (.../ClosingStructuresCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -386,10 +386,10 @@ TestDelegate call = () => isValid = ClosingStructuresCalculationService.Validate(calculation, assessmentSectionStub); // Assert - var exception = Assert.Throws(call); - Assert.AreEqual("inputParameters", exception.ParamName); - StringAssert.StartsWith("The value of argument 'inputParameters' (9001) is invalid for Enum type 'ClosingStructureInflowModelType'.", - exception.Message); + const string expectedMessage = "The value of argument 'inputParameters' (9001) is invalid for Enum type 'ClosingStructureInflowModelType'."; + string paramName = TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, + expectedMessage).ParamName; + Assert.AreEqual("inputParameters", paramName); Assert.IsFalse(isValid); mockRepository.VerifyAll(); } @@ -450,7 +450,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new ClosingStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new ClosingStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -518,14 +518,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = closingStructuresFailureMechanism.Sections.First(); @@ -612,14 +605,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = closingStructuresFailureMechanism.Sections.First(); @@ -705,14 +691,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = closingStructuresFailureMechanism.Sections.First(); Index: Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/AssessmentSectionHelperTest.cs =================================================================== diff -u -r7fa4481428458d47cc3ec2fe6e75b12a1c539c8d -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/AssessmentSectionHelperTest.cs (.../AssessmentSectionHelperTest.cs) (revision 7fa4481428458d47cc3ec2fe6e75b12a1c539c8d) +++ Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/AssessmentSectionHelperTest.cs (.../AssessmentSectionHelperTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -23,6 +23,7 @@ using Core.Common.Base.Geometry; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; namespace Ringtoets.Common.Data.TestUtil.Test { @@ -37,8 +38,8 @@ var mocks = new MockRepository(); // Call - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mocks); - mocks.ReplayAll(); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mocks); + mocks.ReplayAll(); // Assert Assert.IsNotNull(assessmentSectionStub); @@ -63,8 +64,8 @@ var mocks = new MockRepository(); // Call - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mocks, path); - mocks.ReplayAll(); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mocks, path); + mocks.ReplayAll(); // Assert Assert.IsNotNull(assessmentSectionStub); @@ -87,7 +88,7 @@ var mocks = new MockRepository(); // Call - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(failureMechanism, mocks); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(failureMechanism, mocks); mocks.ReplayAll(); // Assert Index: Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/AssessmentSectionHelper.cs =================================================================== diff -u -r7fa4481428458d47cc3ec2fe6e75b12a1c539c8d -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/AssessmentSectionHelper.cs (.../AssessmentSectionHelper.cs) (revision 7fa4481428458d47cc3ec2fe6e75b12a1c539c8d) +++ Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/AssessmentSectionHelper.cs (.../AssessmentSectionHelper.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -28,7 +28,7 @@ namespace Ringtoets.Common.Data.TestUtil { /// - /// Helper class for testing the assessment section. + /// Helper class for creating assessment sections that can be used for unit tests. /// public static class AssessmentSectionHelper { @@ -60,7 +60,7 @@ private static IAssessmentSection CreateAssessmentSectionStub(IFailureMechanism failureMechanism, MockRepository mockRepository, - bool addBoundaryDatabase, + bool addBoundaryDatabase, string filePath) { var assessmentSectionStub = mockRepository.Stub(); Index: Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Service.Test/GrassCoverErosionInwardsCalculationServiceTest.cs =================================================================== diff -u -rbd73023d5f8926a411da214fb5ce522056a0e30a -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Service.Test/GrassCoverErosionInwardsCalculationServiceTest.cs (.../GrassCoverErosionInwardsCalculationServiceTest.cs) (revision bd73023d5f8926a411da214fb5ce522056a0e30a) +++ Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Service.Test/GrassCoverErosionInwardsCalculationServiceTest.cs (.../GrassCoverErosionInwardsCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -27,6 +27,7 @@ using Core.Common.TestUtil; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; using Ringtoets.Common.Data.DikeProfiles; using Ringtoets.Common.Data.FailureMechanism; using Ringtoets.Common.Data.TestUtil; @@ -52,7 +53,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -91,14 +94,14 @@ // Setup var grassCoverErosionInwardsFailureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); + var invalidFilePath = Path.Combine(testDataPath, "notexisting.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + invalidFilePath); mockRepository.ReplayAll(); - assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "notexisting.sqlite"); - const string name = ""; GrassCoverErosionInwardsCalculation calculation = new GrassCoverErosionInwardsCalculation @@ -139,7 +142,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -184,7 +189,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -219,7 +226,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -270,7 +279,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -304,7 +315,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -349,7 +362,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); var dikeProfile = GetDikeProfile(); @@ -403,7 +418,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); var dikeProfile = GetDikeProfile(); @@ -472,7 +489,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); var dikeProfile = GetDikeProfile(); @@ -539,7 +558,9 @@ var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; @@ -585,11 +606,13 @@ // Setup var grassCoverErosionInwardsFailureMechanism = new GrassCoverErosionInwardsFailureMechanism(); AddSectionToFailureMechanism(grassCoverErosionInwardsFailureMechanism); - + var filePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, mockRepository, filePath); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(grassCoverErosionInwardsFailureMechanism, + mockRepository, + filePath); mockRepository.ReplayAll(); const string name = ""; Index: Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Service.Test/GrassCoverErosionOutwardsWaveConditionsCalculationServiceTest.cs =================================================================== diff -u -rbd73023d5f8926a411da214fb5ce522056a0e30a -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Service.Test/GrassCoverErosionOutwardsWaveConditionsCalculationServiceTest.cs (.../GrassCoverErosionOutwardsWaveConditionsCalculationServiceTest.cs) (revision bd73023d5f8926a411da214fb5ce522056a0e30a) +++ Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Service.Test/GrassCoverErosionOutwardsWaveConditionsCalculationServiceTest.cs (.../GrassCoverErosionOutwardsWaveConditionsCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -27,6 +27,7 @@ using Core.Common.TestUtil; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; using Ringtoets.Common.Data.DikeProfiles; using Ringtoets.Common.Data.TestUtil; using Ringtoets.GrassCoverErosionOutwards.Data; @@ -252,7 +253,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) @@ -300,7 +302,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); switch (calculationType) @@ -360,7 +363,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) @@ -413,7 +417,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) @@ -444,7 +449,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) @@ -477,7 +483,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) @@ -505,7 +512,8 @@ }; var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(grassCoverErosionOutwardsFailureMechanism, + mockRepository); mockRepository.ReplayAll(); using (new HydraRingCalculatorFactoryConfig()) Index: Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Service.Test/HeightStructuresCalculationServiceTest.cs =================================================================== diff -u -r0fc840682ffcce4fc1074e7d6687e90cab58bd2b -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Service.Test/HeightStructuresCalculationServiceTest.cs (.../HeightStructuresCalculationServiceTest.cs) (revision 0fc840682ffcce4fc1074e7d6687e90cab58bd2b) +++ Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Service.Test/HeightStructuresCalculationServiceTest.cs (.../HeightStructuresCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -56,7 +56,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "notexisting.sqlite"); @@ -96,7 +96,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -135,7 +135,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -174,7 +174,8 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), + mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -218,7 +219,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -262,7 +263,8 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), + mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -309,7 +311,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -358,7 +360,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -406,7 +408,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -455,7 +457,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -497,7 +499,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new HeightStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -541,7 +543,7 @@ var heightStructuresFailureMechanism = new HeightStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); heightStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -611,7 +613,7 @@ var heightStructuresFailureMechanism = new HeightStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); heightStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -663,7 +665,7 @@ var heightStructuresFailureMechanism = new HeightStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); heightStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -726,7 +728,7 @@ var heightStructuresFailureMechanism = new HeightStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); heightStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -746,14 +748,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = heightStructuresFailureMechanism.Sections.First(); @@ -811,7 +806,7 @@ var heightStructuresFailureMechanism = new HeightStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(heightStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); heightStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] Index: Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Service.Test/StabilityPointStructuresCalculationServiceTest.cs =================================================================== diff -u -rdf13dff5aedb149d7b566bed9dda68fe9e3a8e02 -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Service.Test/StabilityPointStructuresCalculationServiceTest.cs (.../StabilityPointStructuresCalculationServiceTest.cs) (revision df13dff5aedb149d7b566bed9dda68fe9e3a8e02) +++ Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.Service.Test/StabilityPointStructuresCalculationServiceTest.cs (.../StabilityPointStructuresCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -57,7 +57,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new StabilityPointStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new StabilityPointStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "notexisting.sqlite"); @@ -97,7 +97,7 @@ { // Setup var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new StabilityPointStructuresFailureMechanism(), mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(new StabilityPointStructuresFailureMechanism(), mockRepository); mockRepository.ReplayAll(); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); @@ -141,7 +141,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); mockRepository.ReplayAll(); @@ -193,7 +193,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); mockRepository.ReplayAll(); @@ -583,7 +583,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); mockRepository.ReplayAll(); @@ -623,7 +623,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); assessmentSectionStub.HydraulicBoundaryDatabase.FilePath = Path.Combine(testDataPath, "HRD dutch coast south.sqlite"); mockRepository.ReplayAll(); @@ -697,9 +697,10 @@ // Assert Assert.AreEqual(0, calculationInputs.Length); - var exception = Assert.Throws(call); - Assert.AreEqual("calculation", exception.ParamName); - StringAssert.StartsWith("The value of argument 'calculation' (100) is invalid for Enum type 'StabilityPointStructureInflowModelType'.", exception.Message); + const string expectedMessage = "The value of argument 'calculation' (100) is invalid for Enum type 'StabilityPointStructureInflowModelType'."; + string paramName = TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, + expectedMessage).ParamName; + Assert.AreEqual("calculation", paramName); } mockRepository.VerifyAll(); } @@ -747,9 +748,10 @@ // Assert Assert.AreEqual(0, calculationInputs.Length); - var exception = Assert.Throws(call); - Assert.AreEqual("calculation", exception.ParamName); - StringAssert.StartsWith("The value of argument 'calculation' (100) is invalid for Enum type 'LoadSchematizationType'.", exception.Message); + const string expectedMessage = "The value of argument 'calculation' (100) is invalid for Enum type 'LoadSchematizationType'."; + string paramName = TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, + expectedMessage).ParamName; + Assert.AreEqual("calculation", paramName); } mockRepository.VerifyAll(); } @@ -764,7 +766,7 @@ var stabilityPointStructuresFailureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); stabilityPointStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -785,14 +787,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = stabilityPointStructuresFailureMechanism.Sections.First(); @@ -897,7 +892,7 @@ var stabilityPointStructuresFailureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); stabilityPointStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -918,14 +913,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = stabilityPointStructuresFailureMechanism.Sections.First(); @@ -1030,7 +1018,7 @@ var stabilityPointStructuresFailureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); stabilityPointStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -1051,14 +1039,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = stabilityPointStructuresFailureMechanism.Sections.First(); @@ -1163,7 +1144,7 @@ var stabilityPointStructuresFailureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(stabilityPointStructuresFailureMechanism, mockRepository); mockRepository.ReplayAll(); stabilityPointStructuresFailureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -1184,14 +1165,7 @@ if (useForeshore) { - calculation.InputParameters.ForeshoreProfile = new ForeshoreProfile(new Point2D(0, 0), - new[] - { - new Point2D(1, 1), - new Point2D(2, 2) - }, - useBreakWater ? new BreakWater(BreakWaterType.Wall, 3.0) : null, - new ForeshoreProfile.ConstructionProperties()); + calculation.InputParameters.ForeshoreProfile = new TestForeshoreProfile(useBreakWater); } FailureMechanismSection failureMechanismSection = stabilityPointStructuresFailureMechanism.Sections.First(); @@ -1297,7 +1271,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); mockRepository.ReplayAll(); failureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -1367,7 +1341,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); mockRepository.ReplayAll(); failureMechanism.AddSection(new FailureMechanismSection("test section", new[] @@ -1426,7 +1400,7 @@ var failureMechanism = new StabilityPointStructuresFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStub(failureMechanism, mockRepository); mockRepository.ReplayAll(); failureMechanism.AddSection(new FailureMechanismSection("test section", new[] Index: Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Integration.Test/StabilityStoneCoverWaveConditionsCalculationActivityIntegrationTest.cs =================================================================== diff -u -rbd73023d5f8926a411da214fb5ce522056a0e30a -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Integration.Test/StabilityStoneCoverWaveConditionsCalculationActivityIntegrationTest.cs (.../StabilityStoneCoverWaveConditionsCalculationActivityIntegrationTest.cs) (revision bd73023d5f8926a411da214fb5ce522056a0e30a) +++ Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Integration.Test/StabilityStoneCoverWaveConditionsCalculationActivityIntegrationTest.cs (.../StabilityStoneCoverWaveConditionsCalculationActivityIntegrationTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -29,6 +29,7 @@ using Core.Common.TestUtil; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; using Ringtoets.Common.Data.TestUtil; using Ringtoets.HydraRing.Calculation.Calculator.Factory; using Ringtoets.HydraRing.Calculation.Data; @@ -145,8 +146,8 @@ StabilityStoneCoverWaveConditionsCalculation calculation = GetValidCalculation(); StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(stabilityStoneCoverFailureMechanism, - mockRepository); + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase(stabilityStoneCoverFailureMechanism, + mockRepository); var activity = new StabilityStoneCoverWaveConditionsCalculationActivity(calculation, validFilePath, stabilityStoneCoverFailureMechanism, Index: Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Service.Test/StabilityStoneCoverWaveConditionsCalculationServiceTest.cs =================================================================== diff -u -rbd73023d5f8926a411da214fb5ce522056a0e30a -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Service.Test/StabilityStoneCoverWaveConditionsCalculationServiceTest.cs (.../StabilityStoneCoverWaveConditionsCalculationServiceTest.cs) (revision bd73023d5f8926a411da214fb5ce522056a0e30a) +++ Ringtoets/StabilityStoneCover/test/Ringtoets.StabilityStoneCover.Service.Test/StabilityStoneCoverWaveConditionsCalculationServiceTest.cs (.../StabilityStoneCoverWaveConditionsCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -27,6 +27,7 @@ using Core.Common.TestUtil; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; using Ringtoets.Common.Data.DikeProfiles; using Ringtoets.Common.Data.TestUtil; using Ringtoets.HydraRing.Calculation.Calculator.Factory; @@ -239,7 +240,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -296,7 +297,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -365,7 +366,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -400,7 +401,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -468,7 +469,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -495,7 +496,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -524,7 +525,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -550,7 +551,7 @@ StabilityStoneCoverFailureMechanism stabilityStoneCoverFailureMechanism = new StabilityStoneCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( stabilityStoneCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); Index: Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Service.Test/WaveImpactAsphaltCoverWaveConditionsCalculationServiceTest.cs =================================================================== diff -u -rbd73023d5f8926a411da214fb5ce522056a0e30a -r1d64c85fa6d013812d3f38fa09ae4e7ec82480fe --- Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Service.Test/WaveImpactAsphaltCoverWaveConditionsCalculationServiceTest.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationServiceTest.cs) (revision bd73023d5f8926a411da214fb5ce522056a0e30a) +++ Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Service.Test/WaveImpactAsphaltCoverWaveConditionsCalculationServiceTest.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationServiceTest.cs) (revision 1d64c85fa6d013812d3f38fa09ae4e7ec82480fe) @@ -27,6 +27,7 @@ using Core.Common.TestUtil; using NUnit.Framework; using Rhino.Mocks; +using Ringtoets.Common.Data.AssessmentSection; using Ringtoets.Common.Data.DikeProfiles; using Ringtoets.Common.Data.TestUtil; using Ringtoets.HydraRing.Calculation.Calculator.Factory; @@ -249,7 +250,7 @@ WaveImpactAsphaltCoverFailureMechanism waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -295,7 +296,7 @@ var waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -353,7 +354,7 @@ var waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -404,7 +405,7 @@ var waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -433,7 +434,7 @@ var waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -464,7 +465,7 @@ var waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll(); @@ -490,7 +491,7 @@ WaveImpactAsphaltCoverFailureMechanism waveImpactAsphaltCoverFailureMechanism = new WaveImpactAsphaltCoverFailureMechanism(); var mockRepository = new MockRepository(); - var assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( + IAssessmentSection assessmentSectionStub = AssessmentSectionHelper.CreateAssessmentSectionStubWithoutBoundaryDatabase( waveImpactAsphaltCoverFailureMechanism, mockRepository); mockRepository.ReplayAll();