Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/DikeHeightOutputContextTreeNodeInfoTest.cs =================================================================== diff -u -rae28e58fd62f93375f16284445d6171e2d9fa436 -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/DikeHeightOutputContextTreeNodeInfoTest.cs (.../DikeHeightOutputContextTreeNodeInfoTest.cs) (revision ae28e58fd62f93375f16284445d6171e2d9fa436) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/DikeHeightOutputContextTreeNodeInfoTest.cs (.../DikeHeightOutputContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -100,7 +100,7 @@ public void ForeColor_HasNoOutput_ReturnGrayText() { // Setup - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput( new TestOvertoppingOutput(0.5), @@ -119,7 +119,7 @@ public void ForeColor_HasOutput_ReturnControlText() { // Setup - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput( new TestOvertoppingOutput(0.5), Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -rae28e58fd62f93375f16284445d6171e2d9fa436 -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs) (revision ae28e58fd62f93375f16284445d6171e2d9fa436) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -120,7 +120,7 @@ mocks.ReplayAll(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = hasOutput ? new TestGrassCoverErosionInwardsOutput() @@ -156,7 +156,7 @@ var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); var assessmentSection = new AssessmentSectionStub(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); var menuBuilder = mocks.StrictMock(); @@ -217,7 +217,7 @@ assessmentSection.Stub(a => a.HydraulicBoundaryDatabase).Return(hydraulicBoundaryDatabase); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); @@ -280,7 +280,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); @@ -315,7 +315,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -357,7 +357,7 @@ DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -399,7 +399,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -448,7 +448,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -512,7 +512,7 @@ DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -575,7 +575,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -607,7 +607,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocks, "invalidFilePath"); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -651,7 +651,7 @@ assessmentSection.Stub(a => a.HydraulicBoundaryDatabase).Return(hydraulicBoundaryDatabase); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -682,7 +682,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -714,7 +714,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocks, "invalidFilePath"); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -757,7 +757,7 @@ assessmentSection.Stub(a => a.HydraulicBoundaryDatabase).Return(hydraulicBoundaryDatabase); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); var nodeData = new GrassCoverErosionInwardsCalculationScenarioContext(calculation, parent, failureMechanism, assessmentSection); @@ -813,7 +813,7 @@ assessmentSection.Stub(a => a.HydraulicBoundaryDatabase).Return(hydraulicBoundaryDatabase); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -901,7 +901,7 @@ assessmentSection.Stub(a => a.HydraulicBoundaryDatabase).Return(hydraulicBoundaryDatabase); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { InputParameters = { @@ -979,7 +979,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -1014,7 +1014,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; @@ -1066,7 +1066,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var parent = new CalculationGroup(); - var calculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; @@ -1117,7 +1117,7 @@ { // Setup var group = new CalculationGroup(); - var elementToBeRemoved = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var elementToBeRemoved = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); var observer = mocks.StrictMock(); var assessmentSection = mocks.Stub(); @@ -1135,7 +1135,7 @@ mocks.ReplayAll(); group.Children.Add(elementToBeRemoved); - group.Children.Add(new GrassCoverErosionInwardsCalculationScenario(double.NaN)); + group.Children.Add(new GrassCoverErosionInwardsCalculationScenario(0.1)); group.Attach(observer); // Precondition @@ -1186,21 +1186,21 @@ private static IEnumerable GetCalculationConfigurationsWithIllustrationPoints() { var random = new Random(21); - var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null, null) }; - var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), new TestDikeHeightOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null) }; - var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(double.NaN) + var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculationScenario(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), null, Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationGroupContextTreeNodeInfoTest.cs =================================================================== diff -u -r9112e9c014cded1efbcffbe95d260bcf7cf137fd -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationGroupContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationGroupContextTreeNodeInfoTest.cs) (revision 9112e9c014cded1efbcffbe95d260bcf7cf137fd) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationGroupContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationGroupContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -148,7 +148,7 @@ var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); var group = new CalculationGroup(); var childGroup = new CalculationGroup(); - var childCalculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var childCalculation = new GrassCoverErosionInwardsCalculationScenario(0.1); group.Children.Add(childGroup); group.Children.Add(calculationItem); @@ -433,12 +433,12 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var nodeData = new GrassCoverErosionInwardsCalculationGroupContext(group, @@ -555,7 +555,7 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; @@ -595,7 +595,7 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -642,7 +642,7 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -694,7 +694,7 @@ var calculation2Observer = mocks.StrictMock(); DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); - var calculation1 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation1 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -704,7 +704,7 @@ calculation1.Attach(calculation1Observer); calculation1.InputParameters.Attach(calculation1InputObserver); - var calculation2 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation2 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -766,7 +766,7 @@ var calculation2Observer = mocks.StrictMock(); DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); - var calculation1 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation1 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -777,7 +777,7 @@ calculation1.Attach(calculation1Observer); calculation1.InputParameters.Attach(calculation1InputObserver); - var calculation2 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation2 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -858,7 +858,7 @@ calculation2Observer.Expect(obs => obs.UpdateObserver()); DikeProfile dikeProfile = DikeProfileTestFactory.CreateDikeProfile(); - var calculation1 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation1 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -869,7 +869,7 @@ calculation1.Attach(calculation1Observer); calculation1.InputParameters.Attach(calculation1InputObserver); - var calculation2 = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation2 = new GrassCoverErosionInwardsCalculation(0.1) { InputParameters = { @@ -942,12 +942,12 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocks, "invalidFilePath"); @@ -998,14 +998,14 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; string validFilePath = Path.Combine(testDataPath, "complete.sqlite"); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); var hydraulicBoundaryDatabase = new HydraulicBoundaryDatabase { @@ -1050,12 +1050,12 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var nodeData = new GrassCoverErosionInwardsCalculationGroupContext(group, @@ -1105,12 +1105,12 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocks, "invalidFilePath"); @@ -1162,14 +1162,14 @@ { Children = { - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; string validFilePath = Path.Combine(testDataPath, "complete.sqlite"); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); var hydraulicBoundaryDatabase = new HydraulicBoundaryDatabase { @@ -1284,7 +1284,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -1295,7 +1295,7 @@ { calculationWithIllustrationPoints, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; @@ -1326,7 +1326,7 @@ IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocks); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -1336,7 +1336,7 @@ Children = { calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; @@ -1364,12 +1364,12 @@ public void GivenCalculationsWithIllustrationPoints_WhenClearIllustrationPointsClickedAndAborted_ThenInquiryAndIllustrationPointsNotCleared() { // Given - var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -1380,7 +1380,7 @@ { calculationWithIllustrationPoints, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; @@ -1431,12 +1431,12 @@ public void GivenCalculationsWithIllustrationPoints_WhenClearIllustrationPointsClickedAndContinued_ThenInquiryAndIllustrationPointsCleared() { // Given - var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -1447,7 +1447,7 @@ { calculationWithIllustrationPoints, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } }; @@ -1505,7 +1505,7 @@ var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "A", InputParameters = @@ -1514,7 +1514,7 @@ DikeProfile = DikeProfileTestFactory.CreateDikeProfile() } }); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "B", InputParameters = @@ -1575,7 +1575,7 @@ var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "A", InputParameters = @@ -1584,7 +1584,7 @@ DikeProfile = DikeProfileTestFactory.CreateDikeProfile() } }); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "B", InputParameters = @@ -1730,7 +1730,7 @@ null, failureMechanism, assessmentSection); - var calculationItem = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationItem = new GrassCoverErosionInwardsCalculation(0.1) { Name = "Nieuwe berekening" }; @@ -1776,7 +1776,7 @@ DikeProfile dikeProfile2 = DikeProfileTestFactory.CreateDikeProfile("Dike profile 2", "id2"); var existingCalculationGroup = new CalculationGroup(); - var existingCalculation = new GrassCoverErosionInwardsCalculationScenario(double.NaN); + var existingCalculation = new GrassCoverErosionInwardsCalculationScenario(0.1); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism { CalculationsGroup = @@ -1909,7 +1909,7 @@ { Children = { - new GrassCoverErosionInwardsCalculationScenario(double.NaN) + new GrassCoverErosionInwardsCalculationScenario(0.1) { Name = existingCalculationName } @@ -2016,7 +2016,7 @@ null, failureMechanism, assessmentSection); - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculation(0.1); observer.Expect(o => o.UpdateObserver()); @@ -2077,21 +2077,21 @@ private static IEnumerable GetCalculationConfigurationsWithIllustrationPoints() { var random = new Random(21); - var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null, null) }; - var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), new TestDikeHeightOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null) }; - var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), null, Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationsContextTreeNodeInfoTest.cs =================================================================== diff -u -rae28e58fd62f93375f16284445d6171e2d9fa436 -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationsContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationsContextTreeNodeInfoTest.cs) (revision ae28e58fd62f93375f16284445d6171e2d9fa436) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsCalculationsContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsCalculationsContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -257,7 +257,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocksRepository); var nodeData = new GrassCoverErosionInwardsCalculationsContext(failureMechanism, assessmentSection); @@ -290,7 +290,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocksRepository, "invalidFilePath"); @@ -325,7 +325,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); string validFilePath = Path.Combine(testDataPath, "complete.sqlite"); @@ -368,7 +368,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocksRepository); @@ -402,7 +402,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(null, mocksRepository, "invalidFilePath"); @@ -437,7 +437,7 @@ { // Setup var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN)); + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1)); string validFilePath = Path.Combine(testDataPath, "complete.sqlite"); @@ -483,7 +483,7 @@ var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "A", InputParameters = @@ -492,7 +492,7 @@ DikeProfile = DikeProfileTestFactory.CreateDikeProfile() } }); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "B", InputParameters = @@ -581,7 +581,7 @@ var menuBuilder = new CustomItemsOnlyContextMenuBuilder(); var failureMechanism = new TestGrassCoverErosionInwardsFailureMechanism(); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "A", InputParameters = @@ -590,7 +590,7 @@ DikeProfile = DikeProfileTestFactory.CreateDikeProfile() } }); - failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(double.NaN) + failureMechanism.CalculationsGroup.Children.Add(new GrassCoverErosionInwardsCalculation(0.1) { Name = "B", InputParameters = @@ -648,7 +648,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocksRepository); - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -661,7 +661,7 @@ { calculation, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } } }; @@ -695,7 +695,7 @@ // Setup IAssessmentSection assessmentSection = AssessmentSectionTestHelper.CreateAssessmentSectionStub(mocksRepository); - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -707,7 +707,7 @@ Children = { calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } } }; @@ -739,12 +739,12 @@ public void GivenCalculationsWithIllustrationPoints_WhenClearIllustrationPointsClickedAndAborted_ThenInquiryAndIllustrationPointsNotCleared() { // Given - var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -760,7 +760,7 @@ { calculationWithIllustrationPoints, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } } }; @@ -809,12 +809,12 @@ public void GivenCalculationsWithIllustrationPoints_WhenClearIllustrationPointsClickedAndContinued_ThenInquiryAndIllustrationPointsCleared() { // Given - var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput(new TestGeneralResultFaultTreeIllustrationPoint()) }; - var calculationWithOutput = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOutput = new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }; @@ -834,7 +834,7 @@ { calculationWithIllustrationPoints, calculationWithOutput, - new GrassCoverErosionInwardsCalculation(double.NaN) + new GrassCoverErosionInwardsCalculation(0.1) } } }; @@ -896,21 +896,21 @@ private static IEnumerable GetCalculationConfigurationsWithIllustrationPoints() { var random = new Random(21); - var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOverToppingOutputWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null, null) }; - var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithDikeHeightRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), new TestDikeHeightOutput(new TestGeneralResultFaultTreeIllustrationPoint()), null) }; - var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculationWithOvertoppingRateWithIllustrationPoints = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput(new TestOvertoppingOutput(random.NextDouble()), null, Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsInputContextTreeNodeInfoTest.cs =================================================================== diff -u -rf8e813a9b33f9bab5505f126995b58ba63aefa5c -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsInputContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsInputContextTreeNodeInfoTest.cs) (revision f8e813a9b33f9bab5505f126995b58ba63aefa5c) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsInputContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsInputContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -88,8 +88,8 @@ { // Setup var grassCoverErosionInwardsInputContext = new GrassCoverErosionInwardsInputContext( - new GrassCoverErosionInwardsInput(double.NaN), - new GrassCoverErosionInwardsCalculation(double.NaN), + new GrassCoverErosionInwardsInput(0.1), + new GrassCoverErosionInwardsCalculation(0.1), new GrassCoverErosionInwardsFailureMechanism(), mocksRepository.Stub()); @@ -107,8 +107,8 @@ { // Setup var grassCoverErosionInwardsInputContext = new GrassCoverErosionInwardsInputContext( - new GrassCoverErosionInwardsInput(double.NaN), - new GrassCoverErosionInwardsCalculation(double.NaN), + new GrassCoverErosionInwardsInput(0.1), + new GrassCoverErosionInwardsCalculation(0.1), new GrassCoverErosionInwardsFailureMechanism(), mocksRepository.Stub()); Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsOutputContextTreeNodeInfoTest.cs =================================================================== diff -u -r2ce31f95c63ed49dff8df2d2fdc03960ed20c9df -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsOutputContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsOutputContextTreeNodeInfoTest.cs) (revision 2ce31f95c63ed49dff8df2d2fdc03960ed20c9df) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/GrassCoverErosionInwardsOutputContextTreeNodeInfoTest.cs (.../GrassCoverErosionInwardsOutputContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -99,7 +99,7 @@ var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); // Call - Color color = info.ForeColor(new GrassCoverErosionInwardsOutputContext(new GrassCoverErosionInwardsCalculation(double.NaN), + Color color = info.ForeColor(new GrassCoverErosionInwardsOutputContext(new GrassCoverErosionInwardsCalculation(0.1), failureMechanism, assessmentSection)); @@ -119,7 +119,7 @@ var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); // Call - Color color = info.ForeColor(new GrassCoverErosionInwardsOutputContext(new GrassCoverErosionInwardsCalculation(double.NaN) + Color color = info.ForeColor(new GrassCoverErosionInwardsOutputContext(new GrassCoverErosionInwardsCalculation(0.1) { Output = new TestGrassCoverErosionInwardsOutput() }, failureMechanism, assessmentSection)); @@ -151,7 +151,7 @@ var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var grassCoverErosionInwardsCalculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var grassCoverErosionInwardsCalculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = hasOutput ? new TestGrassCoverErosionInwardsOutput() : null }; Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingOutputContextTreeNodeInfoTest.cs =================================================================== diff -u -r2ce31f95c63ed49dff8df2d2fdc03960ed20c9df -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingOutputContextTreeNodeInfoTest.cs (.../OvertoppingOutputContextTreeNodeInfoTest.cs) (revision 2ce31f95c63ed49dff8df2d2fdc03960ed20c9df) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingOutputContextTreeNodeInfoTest.cs (.../OvertoppingOutputContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -105,7 +105,7 @@ mocks.ReplayAll(); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN); + var calculation = new GrassCoverErosionInwardsCalculation(0.1); // Call Color color = info.ForeColor(new OvertoppingOutputContext(calculation, failureMechanism, assessmentSection)); @@ -122,7 +122,7 @@ mocks.ReplayAll(); var failureMechanism = new GrassCoverErosionInwardsFailureMechanism(); - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput( new TestOvertoppingOutput(0.5), Index: Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingRateOutputContextTreeNodeInfoTest.cs =================================================================== diff -u -r2ce31f95c63ed49dff8df2d2fdc03960ed20c9df -r19fe78dad099e732a640666a868b42d93b599991 --- Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingRateOutputContextTreeNodeInfoTest.cs (.../OvertoppingRateOutputContextTreeNodeInfoTest.cs) (revision 2ce31f95c63ed49dff8df2d2fdc03960ed20c9df) +++ Riskeer/GrassCoverErosionInwards/test/Riskeer.GrassCoverErosionInwards.Plugin.Test/TreeNodeInfos/OvertoppingRateOutputContextTreeNodeInfoTest.cs (.../OvertoppingRateOutputContextTreeNodeInfoTest.cs) (revision 19fe78dad099e732a640666a868b42d93b599991) @@ -100,7 +100,7 @@ public void ForeColor_HasNoOutput_ReturnGrayText() { // Setup - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput( new TestOvertoppingOutput(0.5), @@ -119,7 +119,7 @@ public void ForeColor_HasOutput_ReturnControlText() { // Setup - var calculation = new GrassCoverErosionInwardsCalculation(double.NaN) + var calculation = new GrassCoverErosionInwardsCalculation(0.1) { Output = new GrassCoverErosionInwardsOutput( new TestOvertoppingOutput(0.5),