Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.IO.Test/Configurations/Helpers/ConfigurationClosingStructureInflowModelTypeConverterTest.cs =================================================================== diff -u -r39864a3af725b9bb35bf4aa3e1774fb1c47a9270 -re772d0383cfbaf86b76034071d206af304a0de4d --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.IO.Test/Configurations/Helpers/ConfigurationClosingStructureInflowModelTypeConverterTest.cs (.../ConfigurationClosingStructureInflowModelTypeConverterTest.cs) (revision 39864a3af725b9bb35bf4aa3e1774fb1c47a9270) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.IO.Test/Configurations/Helpers/ConfigurationClosingStructureInflowModelTypeConverterTest.cs (.../ConfigurationClosingStructureInflowModelTypeConverterTest.cs) (revision e772d0383cfbaf86b76034071d206af304a0de4d) @@ -117,6 +117,20 @@ } [Test] + public void ConvertTo_InvalidDestinationType_ThrowsNotSupportedException() + { + // Setup + var random = new Random(21); + var converter = new ConfigurationClosingStructureInflowModelTypeConverter(); + + // Call + TestDelegate call = () => converter.ConvertTo(random.NextEnumValue(), typeof(object)); + + // Assert + Assert.Throws(call); + } + + [Test] [TestCase(ConfigurationClosingStructureInflowModelType.FloodedCulvert, ClosingStructureInflowModelType.FloodedCulvert)] [TestCase(ConfigurationClosingStructureInflowModelType.LowSill, ClosingStructureInflowModelType.LowSill)] [TestCase(ConfigurationClosingStructureInflowModelType.VerticalWall, ClosingStructureInflowModelType.VerticalWall)] Index: Ringtoets/Common/test/Ringtoets.Common.IO.Test/Configurations/Helpers/ConfigurationBreakWaterTypeConverterTest.cs =================================================================== diff -u -r39864a3af725b9bb35bf4aa3e1774fb1c47a9270 -re772d0383cfbaf86b76034071d206af304a0de4d --- Ringtoets/Common/test/Ringtoets.Common.IO.Test/Configurations/Helpers/ConfigurationBreakWaterTypeConverterTest.cs (.../ConfigurationBreakWaterTypeConverterTest.cs) (revision 39864a3af725b9bb35bf4aa3e1774fb1c47a9270) +++ Ringtoets/Common/test/Ringtoets.Common.IO.Test/Configurations/Helpers/ConfigurationBreakWaterTypeConverterTest.cs (.../ConfigurationBreakWaterTypeConverterTest.cs) (revision e772d0383cfbaf86b76034071d206af304a0de4d) @@ -117,6 +117,20 @@ } [Test] + public void ConvertTo_InvalidDestinationType_ThrowsNotSupportedException() + { + // Setup + var random = new Random(21); + var converter = new ConfigurationBreakWaterTypeConverter(); + + // Call + TestDelegate call = () => converter.ConvertTo(random.NextEnumValue(), typeof(object)); + + // Assert + Assert.Throws(call); + } + + [Test] [TestCase(ConfigurationBreakWaterType.Caisson, BreakWaterType.Caisson)] [TestCase(ConfigurationBreakWaterType.Dam, BreakWaterType.Dam)] [TestCase(ConfigurationBreakWaterType.Wall, BreakWaterType.Wall)]