Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/HeightStructures/HeightStructuresFailureMechanismMetaEntityReadExtensionsTest.cs =================================================================== diff -u -rf7036a73fff399ef3c8524ffe9099e9b8fcbf3d8 -rfbe227cf3a6743302f63c1bd3281feda0273192c --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/HeightStructures/HeightStructuresFailureMechanismMetaEntityReadExtensionsTest.cs (.../HeightStructuresFailureMechanismMetaEntityReadExtensionsTest.cs) (revision f7036a73fff399ef3c8524ffe9099e9b8fcbf3d8) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/HeightStructures/HeightStructuresFailureMechanismMetaEntityReadExtensionsTest.cs (.../HeightStructuresFailureMechanismMetaEntityReadExtensionsTest.cs) (revision fbe227cf3a6743302f63c1bd3281feda0273192c) @@ -19,8 +19,10 @@ // Stichting Deltares and remain full property of Stichting Deltares at all times. // All rights reserved. +using System; using Application.Ringtoets.Storage.DbContext; using Application.Ringtoets.Storage.Read.HeightStructures; +using Core.Common.TestUtil; using NUnit.Framework; using Ringtoets.Common.Data.TestUtil; using Ringtoets.HeightStructures.Data; @@ -31,12 +33,23 @@ public class HeightStructuresFailureMechanismMetaEntityReadExtensionsTest { [Test] + public void ReadHeightStructuresFailureMechanism_EntityNull_ThrowsArgumentNullException() + { + // Call + TestDelegate test = () => ((HeightStructuresFailureMechanismMetaEntity) null).Read(); + + // Assert + var exception = Assert.Throws(test); + Assert.AreEqual("entity", exception.ParamName); + } + + [Test] public void Read_Always_ReturnGeneralHeightStructuresInput() { // Setup var entity = new HeightStructuresFailureMechanismMetaEntity { - N = 3 + N = new Random(39).NextRoundedDouble(1.0, 20.0) }; // Call