Index: Ringtoets/Piping/test/Ringtoets.Piping.Data.Test/StochasticSoilModelTest.cs =================================================================== diff -u -r24145cb7feea063e2986e8f4b2270bb2a478b3fd -r34f1b5a53b9c554d1a0a35365da4f8d258117304 --- Ringtoets/Piping/test/Ringtoets.Piping.Data.Test/StochasticSoilModelTest.cs (.../StochasticSoilModelTest.cs) (revision 24145cb7feea063e2986e8f4b2270bb2a478b3fd) +++ Ringtoets/Piping/test/Ringtoets.Piping.Data.Test/StochasticSoilModelTest.cs (.../StochasticSoilModelTest.cs) (revision 34f1b5a53b9c554d1a0a35365da4f8d258117304) @@ -1,4 +1,25 @@ -using System; +// Copyright (C) Stichting Deltares 2016. 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 Core.Common.Base; using Core.Common.Base.Geometry; @@ -218,8 +239,28 @@ [Test] public void Update_ModelWithRemovedProfile_ProfileRemoved() { - var modelName = "name"; + // Setup + var profileName = "A"; + var soilProfile = new PipingSoilProfile(profileName, -2, CreateLayers(), SoilProfileType.SoilProfile1D, -5); + var expectedRemovedProfile = new StochasticSoilProfile(0.2, SoilProfileType.SoilProfile1D, 3) + { + SoilProfile = soilProfile + }; StochasticSoilModel model = CreateEmptyModel(); + model.StochasticSoilProfiles.Add(expectedRemovedProfile); + + StochasticSoilModel otherModel = CreateEmptyModel(); + + // Call + StochasticSoilModelProfileDifference difference = model.Update(otherModel); + + // Assert + CollectionAssert.IsEmpty(difference.AddedProfiles); + CollectionAssert.IsEmpty(difference.UpdatedProfiles); + CollectionAssert.AreEqual(new[] + { + expectedRemovedProfile + }, difference.RemovedProfiles); } [Test]