Index: DamEngine/trunk/src/Deltares.DamEngine.IntegrationTests/IntegrationTests/MultiCoreMacroStabilityTests.cs =================================================================== diff -u -r4427 -r4439 --- DamEngine/trunk/src/Deltares.DamEngine.IntegrationTests/IntegrationTests/MultiCoreMacroStabilityTests.cs (.../MultiCoreMacroStabilityTests.cs) (revision 4427) +++ DamEngine/trunk/src/Deltares.DamEngine.IntegrationTests/IntegrationTests/MultiCoreMacroStabilityTests.cs (.../MultiCoreMacroStabilityTests.cs) (revision 4439) @@ -424,11 +424,11 @@ } } - [Test, Category("MultiCore")] - [TestCase(1, true)] - [TestCase(4, true)] - [TestCase(16, true)] - [TestCase(1, false)] + [Test] //, Category("MultiCore")] + [TestCase(1, true), Category("MultiCore")] + [TestCase(4, true), Category("MultiCore")] + [TestCase(16, true), Category("MultiCore")] + [TestCase(1, false), Category("MultiCore")] [TestCase(4, false), Category("Work_In_Progress")] [TestCase(16, false), Category("Work_In_Progress")] public void DesignBishopAdaptionWithScenariosForHeadPl3CalculatesCorrect(int maxCores, bool justOneScenario) @@ -447,9 +447,7 @@ var calcDir = engineInterface.DamProjectData.CalculationMap + "_Cores_" + maxCores; if (justOneScenario) { - var firstScenario = engineInterface.DamProjectData.Dike.Locations.First().Scenarios.First(); - engineInterface.DamProjectData.Dike.ClearScenarios(); - engineInterface.DamProjectData.Dike.AddScenarioToAllLocations(firstScenario); + engineInterface.DamProjectData.Dike.ClearLocationScenariosExceptFirst(); calcDir = engineInterface.DamProjectData.CalculationMap + "_OneScenario_Cores_" + maxCores; } @@ -468,7 +466,7 @@ if (justOneScenario) { Assert.AreEqual(9, output.Results.CalculationResults.Length); - Assert.AreEqual(1465, output.Results.CalculationMessages.Length); + Assert.AreEqual(1430, output.Results.CalculationMessages.Length); } else { Index: DamEngine/trunk/src/Deltares.DamEngine.Calculators/PlLinesCreator/PlLinesCreator.cs =================================================================== diff -u -r4248 -r4439 --- DamEngine/trunk/src/Deltares.DamEngine.Calculators/PlLinesCreator/PlLinesCreator.cs (.../PlLinesCreator.cs) (revision 4248) +++ DamEngine/trunk/src/Deltares.DamEngine.Calculators/PlLinesCreator/PlLinesCreator.cs (.../PlLinesCreator.cs) (revision 4439) @@ -553,7 +553,7 @@ } } - private static SoilLayer1D GetRelevantAquiferLayer(PlLineType type, SoilProfile1D actualSoilProfile) + private SoilLayer1D GetRelevantAquiferLayer(PlLineType type, SoilProfile1D actualSoilProfile) { IList aquiferLayers = actualSoilProfile.GetAquiferLayers(); // Note : if no aquifers at all, always throw a message @@ -590,7 +590,7 @@ /// Remove redundant points (i.e. lying on a line between its both neighbours) /// /// - private static void RemoveRedundantPoints(PlLine plLine) + private void RemoveRedundantPoints(PlLine plLine) { const double tolerance = 0.001; for (int pointIndex = plLine.Points.Count - 2; pointIndex > 0; pointIndex--) @@ -609,7 +609,7 @@ /// All points should have descending z from dike to polder /// /// - private static void EnsureDescendingLine(PlLine plLine) + private void EnsureDescendingLine(PlLine plLine) { PlLinePoint plPointPrevious = null; foreach (PlLinePoint plPoint in plLine.Points) @@ -967,7 +967,7 @@ /// /// /// - private static void AdaptSoilProfileForSurfaceLevelAccuracy(SoilProfile1D actualSoilProfile, double surfaceLevel) + private void AdaptSoilProfileForSurfaceLevelAccuracy(SoilProfile1D actualSoilProfile, double surfaceLevel) { if (surfaceLevel > actualSoilProfile.TopLevel) { Index: DamEngine/trunk/src/Deltares.DamEngine.Data/General/Dike.cs =================================================================== diff -u -r4412 -r4439 --- DamEngine/trunk/src/Deltares.DamEngine.Data/General/Dike.cs (.../Dike.cs) (revision 4412) +++ DamEngine/trunk/src/Deltares.DamEngine.Data/General/Dike.cs (.../Dike.cs) (revision 4439) @@ -173,28 +173,19 @@ } /// - /// Clears all the scenarios. + /// For all locations, clears all the scenarios except for the first one. /// - public void ClearScenarios() + public void ClearLocationScenariosExceptFirst() { + foreach (Location location in Locations) { + var scenario = location.Scenarios[0].CloneInput(); location.Scenarios.Clear(); + location.Scenarios.Add(scenario); } } - /// - /// Adds given scenario to all locations - /// - /// - public void AddScenarioToAllLocations(DesignScenario designScenario) - { - foreach (Location location in Locations) - { - location.Scenarios.Add(designScenario); - } - } - public string Description { get; set; } = ""; ///