Index: Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/PresentationObjects/GrassCoverErosionOutwardsWaveConditionsCalculationInputContext.cs
===================================================================
diff -u
--- Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/PresentationObjects/GrassCoverErosionOutwardsWaveConditionsCalculationInputContext.cs (revision 0)
+++ Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/PresentationObjects/GrassCoverErosionOutwardsWaveConditionsCalculationInputContext.cs (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -0,0 +1,46 @@
+// Copyright (C) Stichting Deltares 2016. All rights reserved.
+//
+// This file is part of Ringtoets.
+//
+// Ringtoets is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+using System;
+using Ringtoets.Common.Data.AssessmentSection;
+using Ringtoets.GrassCoverErosionOutwards.Data;
+using Ringtoets.Revetment.Data;
+
+namespace Ringtoets.GrassCoverErosionOutwards.Forms.PresentationObjects
+{
+ ///
+ /// Presentation object for the input of .
+ ///
+ public class GrassCoverErosionOutwardsWaveConditionsCalculationInputContext : GrassCoverErosionOutwardsContext
+ {
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ /// The wrapped .
+ /// The failure mechanism which the context belongs to.
+ /// The assessment section which the context belongs to.
+ /// Thrown when any input argument is null.
+ public GrassCoverErosionOutwardsWaveConditionsCalculationInputContext(WaveConditionsInput wrappedData,
+ GrassCoverErosionOutwardsFailureMechanism failureMechanism,
+ IAssessmentSection assessmentSection)
+ : base(wrappedData, failureMechanism, assessmentSection) { }
+ }
+}
\ No newline at end of file
Index: Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Ringtoets.GrassCoverErosionOutwards.Forms.csproj
===================================================================
diff -u -r7da3e50da60f27ba27ec7c97c860d8c0b92eb313 -r81245560212cc916b7e268e1f1dc240901d3a5ea
--- Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Ringtoets.GrassCoverErosionOutwards.Forms.csproj (.../Ringtoets.GrassCoverErosionOutwards.Forms.csproj) (revision 7da3e50da60f27ba27ec7c97c860d8c0b92eb313)
+++ Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Ringtoets.GrassCoverErosionOutwards.Forms.csproj (.../Ringtoets.GrassCoverErosionOutwards.Forms.csproj) (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -49,6 +49,7 @@
+
Index: Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/PropertyClasses/GrassCoverErosionOutwardsWaveConditionsCalculationInputContextTest.cs
===================================================================
diff -u
--- Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/PropertyClasses/GrassCoverErosionOutwardsWaveConditionsCalculationInputContextTest.cs (revision 0)
+++ Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/PropertyClasses/GrassCoverErosionOutwardsWaveConditionsCalculationInputContextTest.cs (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -0,0 +1,110 @@
+// Copyright (C) Stichting Deltares 2016. All rights reserved.
+//
+// This file is part of Ringtoets.
+//
+// Ringtoets is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+using System;
+using NUnit.Framework;
+using Rhino.Mocks;
+using Ringtoets.Common.Data.AssessmentSection;
+using Ringtoets.GrassCoverErosionOutwards.Data;
+using Ringtoets.GrassCoverErosionOutwards.Forms.PresentationObjects;
+using Ringtoets.Revetment.Data;
+
+namespace Ringtoets.GrassCoverErosionOutwards.Forms.Test.PropertyClasses
+{
+ [TestFixture]
+ public class GrassCoverErosionOutwardsWaveConditionsCalculationInputContextTest
+ {
+ [Test]
+ public void Constructor_ExpectedValues()
+ {
+ // Setup
+ var mocks = new MockRepository();
+ var assessmentSection = mocks.StrictMock();
+ mocks.ReplayAll();
+
+ var input = new WaveConditionsInput();
+ var failureMechanism = new GrassCoverErosionOutwardsFailureMechanism();
+
+ // Call
+ var context = new GrassCoverErosionOutwardsWaveConditionsCalculationInputContext(input, failureMechanism, assessmentSection);
+
+ // Assert
+ Assert.IsInstanceOf>(context);
+ Assert.AreSame(input, context.WrappedData);
+ Assert.AreSame(failureMechanism, context.FailureMechanism);
+ Assert.AreSame(assessmentSection, context.AssessmentSection);
+ mocks.VerifyAll();
+ }
+
+ [Test]
+ public void Constructor_InputNull_ThrowsArgumentNullException()
+ {
+ // Setup
+ var mocks = new MockRepository();
+ var assessmentSection = mocks.StrictMock();
+ mocks.ReplayAll();
+
+ var failureMechanism = new GrassCoverErosionOutwardsFailureMechanism();
+
+ // Call
+ TestDelegate test = () => new GrassCoverErosionOutwardsWaveConditionsCalculationInputContext(null, failureMechanism, assessmentSection);
+
+ // Assert
+ var exception = Assert.Throws(test);
+ Assert.AreEqual("wrappedData", exception.ParamName);
+ mocks.VerifyAll();
+ }
+
+ [Test]
+ public void Constructor_FailureMechanismNull_ThrowsArgumentNullException()
+ {
+ // Setup
+ var mocks = new MockRepository();
+ var assessmentSection = mocks.StrictMock();
+ mocks.ReplayAll();
+
+ var input = new WaveConditionsInput();
+
+ // Call
+ TestDelegate test = () => new GrassCoverErosionOutwardsWaveConditionsCalculationInputContext(input, null, assessmentSection);
+
+ // Assert
+ var exception = Assert.Throws(test);
+ Assert.AreEqual("failureMechanism", exception.ParamName);
+ mocks.VerifyAll();
+ }
+
+ [Test]
+ public void Constructor_AssessmentSectionNull_ThrowsArgumentNullException()
+ {
+ // Setup
+ var input = new WaveConditionsInput();
+ var failureMechanism = new GrassCoverErosionOutwardsFailureMechanism();
+
+ // Call
+ TestDelegate test = () => new GrassCoverErosionOutwardsWaveConditionsCalculationInputContext(input, failureMechanism, null);
+
+ // Assert
+ var exception = Assert.Throws(test);
+ Assert.AreEqual("assessmentSection", exception.ParamName);
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Ringtoets.GrassCoverErosionOutwards.Forms.Test.csproj
===================================================================
diff -u -r7da3e50da60f27ba27ec7c97c860d8c0b92eb313 -r81245560212cc916b7e268e1f1dc240901d3a5ea
--- Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Ringtoets.GrassCoverErosionOutwards.Forms.Test.csproj (.../Ringtoets.GrassCoverErosionOutwards.Forms.Test.csproj) (revision 7da3e50da60f27ba27ec7c97c860d8c0b92eb313)
+++ Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Ringtoets.GrassCoverErosionOutwards.Forms.Test.csproj (.../Ringtoets.GrassCoverErosionOutwards.Forms.Test.csproj) (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -78,6 +78,7 @@
+
Index: Ringtoets/WaveImpactAsphaltCover/src/Ringtoets.WaveImpactAsphaltCover.Service/WaveImpactAsphaltCoverWaveConditionsCalculationActivity.cs
===================================================================
diff -u -r0d43b27e8aa5f3bfa5224448946e0332d047b1e3 -r81245560212cc916b7e268e1f1dc240901d3a5ea
--- Ringtoets/WaveImpactAsphaltCover/src/Ringtoets.WaveImpactAsphaltCover.Service/WaveImpactAsphaltCoverWaveConditionsCalculationActivity.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationActivity.cs) (revision 0d43b27e8aa5f3bfa5224448946e0332d047b1e3)
+++ Ringtoets/WaveImpactAsphaltCover/src/Ringtoets.WaveImpactAsphaltCover.Service/WaveImpactAsphaltCoverWaveConditionsCalculationActivity.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationActivity.cs) (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -117,14 +117,14 @@
ProgressText = string.Format(Resources.WaveImpactAsphaltCoverWaveConditionsCalculationActivity_OnRun_Calculate_waterlevel_0_, waterLevel);
WaveConditionsOutput output = WaveConditionsCalculationService.Instance.Calculate(waterLevel,
- a,
- b,
- c,
- norm,
- calculation.InputParameters,
- hlcdDirectory,
- assessmentSection.Id,
- calculation.Name);
+ a,
+ b,
+ c,
+ norm,
+ calculation.InputParameters,
+ hlcdDirectory,
+ assessmentSection.Id,
+ calculation.Name);
if (output != null)
{
Index: Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Forms.Test/TreeNodeInfos/WaveImpactAsphaltCoverWaveConditionsCalculationContextTreeNodeInfoTest.cs
===================================================================
diff -u -r0f6049b15bcadf8de3a59c74e829f27bb725c013 -r81245560212cc916b7e268e1f1dc240901d3a5ea
--- Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Forms.Test/TreeNodeInfos/WaveImpactAsphaltCoverWaveConditionsCalculationContextTreeNodeInfoTest.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationContextTreeNodeInfoTest.cs) (revision 0f6049b15bcadf8de3a59c74e829f27bb725c013)
+++ Ringtoets/WaveImpactAsphaltCover/test/Ringtoets.WaveImpactAsphaltCover.Forms.Test/TreeNodeInfos/WaveImpactAsphaltCoverWaveConditionsCalculationContextTreeNodeInfoTest.cs (.../WaveImpactAsphaltCoverWaveConditionsCalculationContextTreeNodeInfoTest.cs) (revision 81245560212cc916b7e268e1f1dc240901d3a5ea)
@@ -741,8 +741,8 @@
Name = "A"
};
var context = new WaveImpactAsphaltCoverWaveConditionsCalculationContext(calculation,
- failureMechanism,
- assessmentSection);
+ failureMechanism,
+ assessmentSection);
using (var treeViewControl = new TreeViewControl())
{
@@ -790,8 +790,8 @@
Name = "A"
};
var context = new WaveImpactAsphaltCoverWaveConditionsCalculationContext(calculation,
- failureMechanism,
- assessmentSection);
+ failureMechanism,
+ assessmentSection);
using (var treeViewControl = new TreeViewControl())
{
@@ -845,8 +845,8 @@
Name = "A"
};
var context = new WaveImpactAsphaltCoverWaveConditionsCalculationContext(calculation,
- failureMechanism,
- assessmentSection);
+ failureMechanism,
+ assessmentSection);
using (var treeViewControl = new TreeViewControl())
{