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 = "";