Index: Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs =================================================================== diff -u -r65ce8c5ab171b234e33e2291998c9d89276db896 -r10a580f9d181a02ed67f162ff3dd10889906142b --- Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs (.../RingtoetsPlugin.cs) (revision 65ce8c5ab171b234e33e2291998c9d89276db896) +++ Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs (.../RingtoetsPlugin.cs) (revision 10a580f9d181a02ed67f162ff3dd10889906142b) @@ -486,7 +486,8 @@ GetViewName = (view, context) => RingtoetsCommonFormsResources.Calculation_Input, GetViewData = context => context.Calculation, CloseForData = RingtoetsPluginHelper.ShouldCloseViewWithCalculationData, - CreateInstance = context => new WaveConditionsInputView(GetWaveConditionsInputViewStyle(context)) + CreateInstance = context => new WaveConditionsInputView(GetWaveConditionsInputViewStyle(context), + () => context.AssessmentSection.GetNormativeAssessmentLevel(context.Calculation.InputParameters.HydraulicBoundaryLocation)) }; yield return new ViewInfo Index: Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/ViewInfos/WaveConditionsInputViewInfoTest.cs =================================================================== diff -u -ra34386047edccd595192296d53343ebd694fb3a3 -r10a580f9d181a02ed67f162ff3dd10889906142b --- Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/ViewInfos/WaveConditionsInputViewInfoTest.cs (.../WaveConditionsInputViewInfoTest.cs) (revision a34386047edccd595192296d53343ebd694fb3a3) +++ Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/ViewInfos/WaveConditionsInputViewInfoTest.cs (.../WaveConditionsInputViewInfoTest.cs) (revision 10a580f9d181a02ed67f162ff3dd10889906142b) @@ -22,6 +22,7 @@ using System.Collections.Generic; using System.Drawing; using System.Linq; +using Core.Common.Base.Data; using Core.Common.Gui.Plugin; using Core.Common.TestUtil; using Core.Components.Chart.Data; @@ -81,7 +82,7 @@ public void GetViewName_Always_ReturnsInputResourceName() { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle())) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel)) { var calculation = new TestWaveConditionsCalculation(); @@ -123,7 +124,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -149,7 +150,7 @@ // Setup var calculationToRemove = new TestWaveConditionsCalculation(); - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculationToRemove }) @@ -173,7 +174,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -201,7 +202,7 @@ null, new GrassCoverErosionOutwardsFailureMechanism(), new AssessmentSection(AssessmentSectionComposition.Dike)); - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -225,7 +226,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -249,7 +250,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -276,7 +277,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -300,7 +301,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -323,7 +324,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -346,7 +347,7 @@ ICalculation calculation) { // Setup - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = new TestWaveConditionsCalculation() }) @@ -379,7 +380,7 @@ } }); - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -416,7 +417,7 @@ null, new GrassCoverErosionOutwardsFailureMechanism(), new AssessmentSection(AssessmentSectionComposition.Dike)); - using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle()) + using (var view = new WaveConditionsInputView(new TestWaveConditionsInputViewStyle(), GetTestNormativeAssessmentLevel) { Data = calculation }) @@ -455,6 +456,11 @@ Assert.AreEqual(revetmentLineColor, revetmentChartData.Style.Color); } + private static RoundedDouble GetTestNormativeAssessmentLevel() + { + return (RoundedDouble) 1.1; + } + #region TestCaseData private const int lowerBoundaryRevetmentChartDataIndex = 1;