Index: dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityInwards/DamMacroStabilityInwardsKernelWrapper.cs =================================================================== diff -u -r843 -r846 --- dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityInwards/DamMacroStabilityInwardsKernelWrapper.cs (.../DamMacroStabilityInwardsKernelWrapper.cs) (revision 843) +++ dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityInwards/DamMacroStabilityInwardsKernelWrapper.cs (.../DamMacroStabilityInwardsKernelWrapper.cs) (revision 846) @@ -22,6 +22,7 @@ using System; using System.Collections.Generic; using System.Data; +using System.IO; using System.Xml.Linq; using Deltares.DamEngine.Calculators.KernelWrappers.Common; using Deltares.DamEngine.Calculators.KernelWrappers.DamMacroStabilityCommon; @@ -65,6 +66,10 @@ CalculationResult = CalculationResult.NoRun }; kernelDataOutput = damMacroStabilityOutput; + + // Make sure the gridposition is Right. + FailureMechanismParametersMStab.MStabParameters.GridPosition = MStabGridPosition.Right; + if (damKernelInput.SubSoilScenario.SegmentFailureMechanismType == FailureMechanismSystemType.StabilityInside) { var model = FailureMechanismParametersMStab.MStabParameters.Model; @@ -74,6 +79,21 @@ model = MStabModelType.Bishop; } +// //ToDo zant tmp Set input for TestRunMacroStabilityTutorialDesign (start) +// //DGeoStabilityExePath, ProjectWorkingPath and SoildatabaseName are not specified in xml from UI +// FailureMechanismParametersMStab.DGeoStabilityExePath = @".\KernelWrappers\DamMacroStabilityCommon\DGeoStability.exe"; +// var absoluteFolder = Path.GetFullPath(Path.Combine(Directory.GetCurrentDirectory())); +// var workingDir = Path.Combine(absoluteFolder, "TestOutStab"); +// FailureMechanismParametersMStab.ProjectWorkingPath = workingDir; +// var soilDB = @"TestFiles\DAM Tutorial Design0.soilmaterials.mdb"; +// damKernelInput.Location.SoildatabaseName = soilDB; +// //MapForSoilGeometries2D has not path in xml. Where is it located? Always in ProjectWorkingPath? +// var soilGeometry2DName = damKernelInput.SubSoilScenario.StiFileName; +// var soilGeometry2DFolder = Path.Combine("TestFiles", +// damKernelInput.Location.StabilityOptions.MapForSoilGeometries2D); +// damKernelInput.SubSoilScenario.StiFileName = Path.Combine(soilGeometry2DFolder, soilGeometry2DName); +// //ToDo zant tmp Set input for TestRunMacroStabilityTutorialDesign (end) + var damMacroStabilityInput = new DamMacroStabilityInput() { DGeoStabilityExePath = FailureMechanismParametersMStab.DGeoStabilityExePath, Index: dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/MacroStabilityTests.cs =================================================================== diff -u -r840 -r846 --- dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/MacroStabilityTests.cs (.../MacroStabilityTests.cs) (revision 840) +++ dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/MacroStabilityTests.cs (.../MacroStabilityTests.cs) (revision 846) @@ -17,7 +17,7 @@ [Test] [Category(Categories.WorkInProgress)] - public void CanPerformMacroStabilityTutorialDesign() + public void TestRunMacroStabilityTutorialDesign() { const string fileName = @"TestFiles\MacroStabilityTutorialDesignInputFile.xml"; string inputString = File.ReadAllText(fileName); Index: dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityCommon/MStabXmlDoc.cs =================================================================== diff -u -r844 -r846 --- dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityCommon/MStabXmlDoc.cs (.../MStabXmlDoc.cs) (revision 844) +++ dam engine/trunk/src/Deltares.DamEngine.Calculators/KernelWrappers/DamMacroStabilityCommon/MStabXmlDoc.cs (.../MStabXmlDoc.cs) (revision 846) @@ -217,6 +217,11 @@ throw new Exception("Not all required data is available"); } +// //ToDo zant tmp Set input for TestRunMacroStabilityTutorialDesign (start) +// failureMechanismParametersMStab.MStabParameters.GeometryCreationOptions.XOffsetSoilGeometry2DOrigin = 8.42; +// failureMechanismParametersMStab.PLLines.Lines[0].Points[4].Z = 2.69; +// //ToDo zant tmp Set input for TestRunMacroStabilityTutorialDesign (end) + DamMStabAssembler assembler = new DamMStabAssembler(); XDocument mstabXML = assembler.CreateDataTransferObject(failureMechanismParametersMStab); return mstabXML; Index: dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/TestFiles/MacroStabilityTutorialDesignInputFile.xml =================================================================== diff -u -r725 -r846 --- dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/TestFiles/MacroStabilityTutorialDesignInputFile.xml (.../MacroStabilityTutorialDesignInputFile.xml) (revision 725) +++ dam engine/trunk/src/Deltares.DamEngine.Interface.Tests/TestFiles/MacroStabilityTutorialDesignInputFile.xml (.../MacroStabilityTutorialDesignInputFile.xml) (revision 846) @@ -2,6 +2,7 @@ + @@ -52,206 +53,206 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -325,4 +326,5 @@ + \ No newline at end of file