Index: Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/TreeNodeInfos/DuneLocationsContextTreeNodeInfoTest.cs =================================================================== diff -u -r330f2e86f2fb575c436cdbb46b6d31bc246ef6fc -r12d03593998d6ac93c231ef947f00ff87c71e100 --- Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/TreeNodeInfos/DuneLocationsContextTreeNodeInfoTest.cs (.../DuneLocationsContextTreeNodeInfoTest.cs) (revision 330f2e86f2fb575c436cdbb46b6d31bc246ef6fc) +++ Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/TreeNodeInfos/DuneLocationsContextTreeNodeInfoTest.cs (.../DuneLocationsContextTreeNodeInfoTest.cs) (revision 12d03593998d6ac93c231ef947f00ff87c71e100) @@ -40,6 +40,7 @@ using Ringtoets.DuneErosion.Data; using Ringtoets.DuneErosion.Data.TestUtil; using Ringtoets.DuneErosion.Forms.PresentationObjects; +using Ringtoets.HydraRing.Calculation.Calculator.Factory; using Ringtoets.HydraRing.Calculation.TestUtil.Calculator; using RingtoetsCommonFormsResources = Ringtoets.Common.Forms.Properties.Resources; @@ -426,6 +427,13 @@ gui.Stub(g => g.MainWindow).Return(mainWindowStub); var observerMock = mocks.StrictMock(); observerMock.Expect(o => o.UpdateObserver()); + + int calculators = failureMechanism.DuneLocations.Count; + var calculatorFactory = mocks.StrictMock(); + calculatorFactory.Expect(cf => cf.CreateDunesBoundaryConditionsCalculator(testDataPath)) + .Return(new TestDunesBoundaryConditionsCalculator()) + .Repeat + .Times(calculators); mocks.ReplayAll(); failureMechanism.DuneLocations.Attach(observerMock); @@ -434,7 +442,7 @@ plugin.Activate(); using (ContextMenuStrip contextMenu = info.ContextMenuStrip(context, null, treeViewControl)) - using (new HydraRingCalculatorFactoryConfig()) + using (new HydraRingCalculatorFactoryConfig(calculatorFactory)) { // Call TestHelper.AssertLogMessages(() => contextMenu.Items[contextMenuCalculateAllIndex].PerformClick(), messages =>