Index: DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs =================================================================== diff -u -r6216 -r6222 --- DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs (.../ConversionHelperTests.cs) (revision 6216) +++ DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs (.../ConversionHelperTests.cs) (revision 6222) @@ -19,6 +19,7 @@ // Stichting Deltares and remain full property of Stichting Deltares at all times. // All rights reserved. +using System; using Deltares.DamEngine.Data.General; using Deltares.DamEngine.Data.General.Sensors; using Deltares.DamEngine.Data.General.TimeSeries; @@ -520,4 +521,26 @@ { Assert.That(ConversionHelper.ConvertToInputDataSourceTypeSensors(dataSourceTypeSensors), Is.EqualTo(inputdataSourceTypeSensors)); } + + [TestCase(FailureMechanismSystemType.StabilityInside, OperationalStaticDataFailureMechanismSystemType.StabilityInside)] + [TestCase(FailureMechanismSystemType.StabilityOutside, OperationalStaticDataFailureMechanismSystemType.StabilityOutside)] + public void CanConvertToOutputOperationalFailureMechanismSystemType(FailureMechanismSystemType failureMechanismSystemType, OperationalStaticDataFailureMechanismSystemType expectedFailureMechanismSystemType) + { + Assert.That(ConversionHelper.ConvertToOutputOperationalFailureMechanismSystemType(failureMechanismSystemType), Is.EqualTo(expectedFailureMechanismSystemType)); + } + + [Test] + public void CanNotConvertPipingToOutputOperationalFailureMechanismSystemType() + { + Assert.Throws(() => ConversionHelper.ConvertToOutputOperationalFailureMechanismSystemType(FailureMechanismSystemType.Piping)); + } + + [TestCase(MStabModelType.Bishop, OperationalStaticDataStabilityModel.Bishop)] + [TestCase(MStabModelType.UpliftVan, OperationalStaticDataStabilityModel.UpliftVan)] + [TestCase(MStabModelType.BishopUpliftVan, OperationalStaticDataStabilityModel.BishopUpliftVan)] + public void CanConvertToOutputOperationalStabilityModel(MStabModelType stabilityModelType, OperationalStaticDataStabilityModel expectedStabilityModel) + { + Assert.That(ConversionHelper.ConvertToOutputOperationalStabilityModel(stabilityModelType), Is.EqualTo(expectedStabilityModel)); + } + } \ No newline at end of file