Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Kernels/AssemblyToolKernelWrapperFactoryTest.cs
===================================================================
diff -u -rbc85d5aa0b1c0eefd837eb1f12b392305ab7a45e -rac3bbab8cdfee2bee4faeea59a40240e79c20d33
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Kernels/AssemblyToolKernelWrapperFactoryTest.cs (.../AssemblyToolKernelWrapperFactoryTest.cs) (revision bc85d5aa0b1c0eefd837eb1f12b392305ab7a45e)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Kernels/AssemblyToolKernelWrapperFactoryTest.cs (.../AssemblyToolKernelWrapperFactoryTest.cs) (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -21,6 +21,7 @@
using NUnit.Framework;
using Ringtoets.AssemblyTool.KernelWrapper.Kernels;
+using Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels;
namespace Ringtoets.AssemblyTool.KernelWrapper.Test.Kernels
{
@@ -50,5 +51,19 @@
// Assert
Assert.AreNotSame(firstFactory, secondFactory);
}
+
+ [Test]
+ public void Instance_WhenSetToInstance_ReturnsThatInstance()
+ {
+ // Setup
+ var firstFactory = new TestAssemblyToolKernelFactory();
+ AssemblyToolKernelWrapperFactory.Instance = firstFactory;
+
+ // Call
+ IAssemblyToolKernelFactory secondFactory = AssemblyToolKernelWrapperFactory.Instance;
+
+ // Assert
+ Assert.AreSame(firstFactory, secondFactory);
+ }
}
}
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Ringtoets.AssemblyTool.KernelWrapper.Test.csproj
===================================================================
diff -u -r7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e -rac3bbab8cdfee2bee4faeea59a40240e79c20d33
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Ringtoets.AssemblyTool.KernelWrapper.Test.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.Test.csproj) (revision 7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.Test/Ringtoets.AssemblyTool.KernelWrapper.Test.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.Test.csproj) (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -30,5 +30,9 @@
{358B6DA2-A1DF-477F-B6AC-C30204265CB0}Ringtoets.AssemblyTool.KernelWrapper
+
+ {0AB432BB-E2CC-42EA-A72C-7AFEF7536B38}
+ Ringtoets.AssemblyTool.KernelWrapper.TestUtil
+
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStubTest.cs
===================================================================
diff -u
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStubTest.cs (revision 0)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStubTest.cs (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -0,0 +1,41 @@
+// 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 NUnit.Framework;
+using Ringtoets.AssemblyTool.KernelWrapper.Kernels.CategoryBoundaries;
+using Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels.CategoryBoundaries;
+
+namespace Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.Kernels.CategoryBoundaries
+{
+ [TestFixture]
+ public class AssemblyCategoryBoundariesKernelStubTest
+ {
+ [Test]
+ public void Constructor_ExpectedValues()
+ {
+ // Call
+ var kernelStub = new AssemblyCategoryBoundariesKernelStub();
+
+ // Assert
+ Assert.IsInstanceOf(kernelStub);
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/TestAssemblyToolKernelFactoryTest.cs
===================================================================
diff -u
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/TestAssemblyToolKernelFactoryTest.cs (revision 0)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Kernels/TestAssemblyToolKernelFactoryTest.cs (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -0,0 +1,56 @@
+// 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 NUnit.Framework;
+using Ringtoets.AssemblyTool.KernelWrapper.Kernels;
+using Ringtoets.AssemblyTool.KernelWrapper.Kernels.CategoryBoundaries;
+using Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels;
+
+namespace Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.Kernels
+{
+ [TestFixture]
+ public class TestAssemblyToolKernelFactoryTest
+ {
+ [Test]
+ public void Constructor_ExpectedProperties()
+ {
+ // Call
+ var factory = new TestAssemblyToolKernelFactory();
+
+ // Assert
+ Assert.IsInstanceOf(factory);
+ Assert.IsNotNull(factory.LastCreatedAssemblyCategoryBoundariesKernel);
+ }
+
+ [Test]
+ public void CreateAssemblyCategoryBoundariesKernel_Always_ReturnLastCreatedAssemblyCategoryBoundariesKernel()
+ {
+ // Setup
+ var factory = new TestAssemblyToolKernelFactory();
+
+ // Call
+ IAssemblyCategoryBoundariesKernel kernel = factory.CreateAssemblyCategoryBoundariesKernel();
+
+ // Assert
+ Assert.AreSame(factory.LastCreatedAssemblyCategoryBoundariesKernel, kernel);
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.csproj
===================================================================
diff -u -r7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e -rac3bbab8cdfee2bee4faeea59a40240e79c20d33
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.csproj) (revision 7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test.csproj) (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -7,15 +7,31 @@
+
+ ..\..\..\..\packages\NUnit.3.9.0\lib\net40\nunit.framework.dll
+
+
+
Copying.licenseheader
+
+
+
+ {358B6DA2-A1DF-477F-B6AC-C30204265CB0}
+ Ringtoets.AssemblyTool.KernelWrapper
+
+
+ {0AB432BB-E2CC-42EA-A72C-7AFEF7536B38}
+ Ringtoets.AssemblyTool.KernelWrapper.TestUtil
+
+
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/packages.config
===================================================================
diff -u
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/packages.config (revision 0)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Test/packages.config (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -0,0 +1,26 @@
+
+
+
+
+
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStub.cs
===================================================================
diff -u
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStub.cs (revision 0)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/CategoryBoundaries/AssemblyCategoryBoundariesKernelStub.cs (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -0,0 +1,30 @@
+// 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 Ringtoets.AssemblyTool.KernelWrapper.Kernels.CategoryBoundaries;
+
+namespace Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels.CategoryBoundaries
+{
+ ///
+ /// Assembly category boundaries kernel stub for testing purposes.
+ ///
+ public class AssemblyCategoryBoundariesKernelStub : IAssemblyCategoryBoundariesKernel {}
+}
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/TestAssemblyToolKernelFactory.cs
===================================================================
diff -u
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/TestAssemblyToolKernelFactory.cs (revision 0)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Kernels/TestAssemblyToolKernelFactory.cs (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -0,0 +1,51 @@
+// 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 Ringtoets.AssemblyTool.KernelWrapper.Kernels;
+using Ringtoets.AssemblyTool.KernelWrapper.Kernels.CategoryBoundaries;
+using Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels.CategoryBoundaries;
+
+namespace Ringtoets.AssemblyTool.KernelWrapper.TestUtil.Kernels
+{
+ ///
+ /// Factory that creates assembly tool kernel stubs for testing purposes.
+ ///
+ public class TestAssemblyToolKernelFactory : IAssemblyToolKernelFactory
+ {
+ ///
+ /// Creates a new instance of .
+ ///
+ public TestAssemblyToolKernelFactory()
+ {
+ LastCreatedAssemblyCategoryBoundariesKernel = new AssemblyCategoryBoundariesKernelStub();
+ }
+
+ ///
+ /// The last created assembly category boundaries kernel.
+ ///
+ public IAssemblyCategoryBoundariesKernel LastCreatedAssemblyCategoryBoundariesKernel { get; }
+
+ public IAssemblyCategoryBoundariesKernel CreateAssemblyCategoryBoundariesKernel()
+ {
+ return LastCreatedAssemblyCategoryBoundariesKernel;
+ }
+ }
+}
\ No newline at end of file
Index: Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.csproj
===================================================================
diff -u -r7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e -rac3bbab8cdfee2bee4faeea59a40240e79c20d33
--- Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.TestUtil.csproj) (revision 7b2dd0c4744b58ea6bf4bfe108d3f6fb487f2d3e)
+++ Ringtoets/AssemblyTool/test/Ringtoets.AssemblyTool.KernelWrapper.TestUtil/Ringtoets.AssemblyTool.KernelWrapper.TestUtil.csproj (.../Ringtoets.AssemblyTool.KernelWrapper.TestUtil.csproj) (revision ac3bbab8cdfee2bee4faeea59a40240e79c20d33)
@@ -11,11 +11,19 @@
+
+
Copying.licenseheader
+
+
+ {358B6DA2-A1DF-477F-B6AC-C30204265CB0}
+ Ringtoets.AssemblyTool.KernelWrapper
+
+
\ No newline at end of file