Index: Ringtoets/Integration/src/Ringtoets.Integration.Data/Assembly/CombinedAssemblyFailureMechanismInputFactory.cs
===================================================================
diff -u
--- Ringtoets/Integration/src/Ringtoets.Integration.Data/Assembly/CombinedAssemblyFailureMechanismInputFactory.cs (revision 0)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Data/Assembly/CombinedAssemblyFailureMechanismInputFactory.cs (revision 260eeac10d6b7fc5fe49c11a8659283a00d5e603)
@@ -0,0 +1,57 @@
+// Copyright (C) Stichting Deltares 2017. 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 System.Collections.Generic;
+using Ringtoets.AssemblyTool.Data;
+using Ringtoets.Common.Data.FailureMechanism;
+
+namespace Ringtoets.Integration.Data.Assembly
+{
+ ///
+ /// Factory that creates instances.
+ ///
+ internal static class CombinedAssemblyFailureMechanismInputFactory
+ {
+ ///
+ /// Creates a collection of .
+ ///
+ /// The assessment section to use.
+ /// The failure mechanisms to build input for.
+ /// An of .
+ /// Thrown when any parameter is null.
+ public static IEnumerable CreateInput(AssessmentSection assessmentSection,
+ IEnumerable failureMechanisms)
+ {
+ if (assessmentSection == null)
+ {
+ throw new ArgumentNullException(nameof(assessmentSection));
+ }
+
+ if (failureMechanisms == null)
+ {
+ throw new ArgumentNullException(nameof(failureMechanisms));
+ }
+
+ return new List();
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/Integration/src/Ringtoets.Integration.Data/Properties/AssemblyInfo.cs
===================================================================
diff -u -r0819cf01b494097b764677be8dd47853e38fc223 -r260eeac10d6b7fc5fe49c11a8659283a00d5e603
--- Ringtoets/Integration/src/Ringtoets.Integration.Data/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 0819cf01b494097b764677be8dd47853e38fc223)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Data/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 260eeac10d6b7fc5fe49c11a8659283a00d5e603)
@@ -20,6 +20,8 @@
// All rights reserved.
using System.Reflection;
+using System.Runtime.CompilerServices;
[assembly: AssemblyTitle("Ringtoets.Integration.Data")]
-[assembly: AssemblyProduct("Ringtoets.Integration.Data")]
\ No newline at end of file
+[assembly: AssemblyProduct("Ringtoets.Integration.Data")]
+[assembly: InternalsVisibleTo("Ringtoets.Integration.Data.Test")]
\ No newline at end of file
Index: Ringtoets/Integration/src/Ringtoets.Integration.Data/Ringtoets.Integration.Data.csproj
===================================================================
diff -u -re6dce9f10ba6b2e89fa58977a50fb7e4c9ceb647 -r260eeac10d6b7fc5fe49c11a8659283a00d5e603
--- Ringtoets/Integration/src/Ringtoets.Integration.Data/Ringtoets.Integration.Data.csproj (.../Ringtoets.Integration.Data.csproj) (revision e6dce9f10ba6b2e89fa58977a50fb7e4c9ceb647)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Data/Ringtoets.Integration.Data.csproj (.../Ringtoets.Integration.Data.csproj) (revision 260eeac10d6b7fc5fe49c11a8659283a00d5e603)
@@ -11,6 +11,7 @@
+
Index: Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Assembly/CombinedAssemblyFailureMechanismInputFactoryTest.cs
===================================================================
diff -u
--- Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Assembly/CombinedAssemblyFailureMechanismInputFactoryTest.cs (revision 0)
+++ Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Assembly/CombinedAssemblyFailureMechanismInputFactoryTest.cs (revision 260eeac10d6b7fc5fe49c11a8659283a00d5e603)
@@ -0,0 +1,75 @@
+// Copyright (C) Stichting Deltares 2017. 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 System.Collections.Generic;
+using System.Linq;
+using Core.Common.TestUtil;
+using NUnit.Framework;
+using Ringtoets.AssemblyTool.Data;
+using Ringtoets.Common.Data.AssessmentSection;
+using Ringtoets.Common.Data.FailureMechanism;
+using Ringtoets.Integration.Data.Assembly;
+
+namespace Ringtoets.Integration.Data.Test.Assembly
+{
+ [TestFixture]
+ public class CombinedAssemblyFailureMechanismInputFactoryTest
+ {
+ [Test]
+ public void CreateInput_AssessmentSectionNull_ThrowsArgumentNullException()
+ {
+ // Call
+ TestDelegate call = () => CombinedAssemblyFailureMechanismInputFactory.CreateInput(null, Enumerable.Empty());
+
+ // Assert
+ var exception = Assert.Throws(call);
+ Assert.AreEqual("assessmentSection", exception.ParamName);
+ }
+
+ [Test]
+ public void CreateInput_failureMechanismsNull_ThrowsArgumentNullException()
+ {
+ // Setup
+ var assessmentSection = new AssessmentSection(new Random(21).NextEnumValue());
+
+ // Call
+ TestDelegate call = () => CombinedAssemblyFailureMechanismInputFactory.CreateInput(assessmentSection, null);
+
+ // Assert
+ var exception = Assert.Throws(call);
+ Assert.AreEqual("failureMechanisms", exception.ParamName);
+ }
+
+ [Test]
+ public void CreateInput_Always_ReturnsEmptyCollection()
+ {
+ // Setup
+ var assessmentSection = new AssessmentSection(new Random(21).NextEnumValue());
+
+ // Call
+ IEnumerable inputs = CombinedAssemblyFailureMechanismInputFactory.CreateInput(assessmentSection, Enumerable.Empty());
+
+ // Assert
+ CollectionAssert.IsEmpty(inputs);
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Ringtoets.Integration.Data.Test.csproj
===================================================================
diff -u -re6dce9f10ba6b2e89fa58977a50fb7e4c9ceb647 -r260eeac10d6b7fc5fe49c11a8659283a00d5e603
--- Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Ringtoets.Integration.Data.Test.csproj (.../Ringtoets.Integration.Data.Test.csproj) (revision e6dce9f10ba6b2e89fa58977a50fb7e4c9ceb647)
+++ Ringtoets/Integration/test/Ringtoets.Integration.Data.Test/Ringtoets.Integration.Data.Test.csproj (.../Ringtoets.Integration.Data.Test.csproj) (revision 260eeac10d6b7fc5fe49c11a8659283a00d5e603)
@@ -19,6 +19,7 @@
+