Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r01e8d3f7c86b2cc7e52606d71e97bd40431a2b25 -r65991df4e411780df91b7005b669d41b51170b3b --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationContextTreeNodeInfoTest.cs) (revision 01e8d3f7c86b2cc7e52606d71e97bd40431a2b25) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationContextTreeNodeInfoTest.cs) (revision 65991df4e411780df91b7005b669d41b51170b3b) @@ -760,7 +760,7 @@ } [Test] - public void ContextMenuStrip_WithForeshoreProfileAndChanges_ContextMenuItemUpdateForeshoreProfileEnabled() + public void ContextMenuStrip_CalculationWithForeshoreProfileAndInputOutOfSync_ContextMenuItemUpdateForeshoreProfileEnabledAndToolTipSet() { // Setup var assessmentSectionStub = mocks.Stub(); @@ -772,7 +772,6 @@ ForeshoreProfile = new TestForeshoreProfile() } }; - calculation.InputParameters.UseBreakWater = true; var nodeData = new ClosingStructuresCalculationContext(calculation, failureMechanism, assessmentSectionStub); @@ -785,6 +784,8 @@ plugin.Gui = gui; + calculation.InputParameters.UseBreakWater = true; + // Call using (ContextMenuStrip menu = info.ContextMenuStrip(nodeData, null, treeViewControl)) { @@ -799,7 +800,7 @@ } [Test] - public void GivenCalculationWithForeshoreProfileSet_WhenUpdatingForeshoreProfileFromContextMenu_ThenCalculationUpdatedAndUpdateObserver() + public void GivenCalculationWithoutOutputAndWithInputOutOfSync_WhenUpdateForeshoreProfileClicked_ThenNoInquiryAndCalculationUpdatedAndInputObserverNotified() { // Given var calculationObserver = mocks.StrictMock(); @@ -816,7 +817,6 @@ ForeshoreProfile = new TestForeshoreProfile(true) } }; - calculation.InputParameters.UseBreakWater = false; var nodeData = new ClosingStructuresCalculationContext(calculation, failureMechanism, assessmentSectionStub); @@ -832,6 +832,8 @@ plugin.Gui = gui; + calculation.InputParameters.UseBreakWater = false; + using (ContextMenuStrip contextMenuStrip = info.ContextMenuStrip(nodeData, null, treeViewControl)) { // Precondition Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationGroupContextTreeNodeInfoTest.cs =================================================================== diff -u -r01e8d3f7c86b2cc7e52606d71e97bd40431a2b25 -r65991df4e411780df91b7005b669d41b51170b3b --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationGroupContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationGroupContextTreeNodeInfoTest.cs) (revision 01e8d3f7c86b2cc7e52606d71e97bd40431a2b25) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Plugin.Test/TreeNodeInfos/ClosingStructuresCalculationGroupContextTreeNodeInfoTest.cs (.../ClosingStructuresCalculationGroupContextTreeNodeInfoTest.cs) (revision 65991df4e411780df91b7005b669d41b51170b3b) @@ -668,7 +668,7 @@ } [Test] - public void ContextMenuStrip_WithForeshoreProfileAndChanges_ContextMenuItemUpdateForeshoreProfilesEnabled() + public void ContextMenuStrip_CalculationGroupWithCalculationWithForeshoreProfileAndInputOutOfSync_ContextMenuItemUpdateForeshoreProfilesEnabledAndToolTipSet() { // Setup var assessmentSection = mocks.Stub(); @@ -677,8 +677,7 @@ { InputParameters = { - ForeshoreProfile = new TestForeshoreProfile(), - UseBreakWater = true + ForeshoreProfile = new TestForeshoreProfile() } }; @@ -701,6 +700,8 @@ plugin.Gui = gui; + calculation.InputParameters.UseBreakWater = true; + // Call using (ContextMenuStrip menu = info.ContextMenuStrip(nodeData, null, treeViewControl)) { @@ -715,7 +716,7 @@ } [Test] - public void GivenCalculationWithForeshoreProfileSet_WhenUpdatingForeshoreProfileFromContextMenu_ThenCalculationInputUpdatedAndObserverNotified() + public void GivenCalculationWithoutOutputAndWithInputOutOfSync_WhenUpdateForeshoreProfilesClicked_ThenNoInquiryAndCalculationUpdatedAndInputObserverNotified() { // Given var calculationObserver = mocks.StrictMock(); @@ -729,8 +730,7 @@ { InputParameters = { - ForeshoreProfile = new TestForeshoreProfile(true), - UseBreakWater = false + ForeshoreProfile = new TestForeshoreProfile(true) } }; @@ -756,6 +756,8 @@ plugin.Gui = gui; + calculation.InputParameters.UseBreakWater = false; + using (ContextMenuStrip contextMenuStrip = info.ContextMenuStrip(nodeData, null, treeViewControl)) { // Precondition Index: Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs =================================================================== diff -u -r01e8d3f7c86b2cc7e52606d71e97bd40431a2b25 -r65991df4e411780df91b7005b669d41b51170b3b --- Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationContextTreeNodeInfoTest.cs) (revision 01e8d3f7c86b2cc7e52606d71e97bd40431a2b25) +++ Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationContextTreeNodeInfoTest.cs) (revision 65991df4e411780df91b7005b669d41b51170b3b) @@ -904,7 +904,7 @@ } [Test] - public void ContextMenuStrip_WithForeshoreProfileAndChanges_ContextMenuItemUpdateForeshoreProfileEnabled() + public void ContextMenuStrip_CalculationWithForeshoreProfileAndInputOutOfSync_ContextMenuItemUpdateForeshoreProfileEnabledAndToolTipSet() { // Setup var assessmentSectionStub = mocks.Stub(); @@ -916,7 +916,6 @@ ForeshoreProfile = new TestForeshoreProfile() } }; - calculation.InputParameters.UseBreakWater = true; var nodeData = new HeightStructuresCalculationContext(calculation, failureMechanism, assessmentSectionStub); @@ -930,6 +929,8 @@ plugin.Gui = gui; + calculation.InputParameters.UseBreakWater = true; + // Call using (ContextMenuStrip menu = info.ContextMenuStrip(nodeData, null, treeViewControl)) { @@ -944,7 +945,7 @@ } [Test] - public void GivenCalculationWithForeshoreProfileSet_WhenUpdatingForeshoreProfileFromContextMenu_ThenCalculationUpdatedAndUpdateObserver() + public void GivenCalculationWithoutOutputAndWithInputOutOfSync_WhenUpdateForeshoreProfileClicked_ThenNoInquiryAndCalculationUpdatedAndInputObserverNotified() { // Given var calculationObserver = mocks.StrictMock(); @@ -961,7 +962,6 @@ ForeshoreProfile = new TestForeshoreProfile(true) } }; - calculation.InputParameters.UseBreakWater = false; var nodeData = new HeightStructuresCalculationContext(calculation, failureMechanism, assessmentSectionStub); @@ -978,6 +978,8 @@ plugin.Gui = guiStub; + calculation.InputParameters.UseBreakWater = false; + using (ContextMenuStrip contextMenuStrip = info.ContextMenuStrip(nodeData, null, treeViewControl)) { // Precondition Index: Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationGroupContextTreeNodeInfoTest.cs =================================================================== diff -u -r01e8d3f7c86b2cc7e52606d71e97bd40431a2b25 -r65991df4e411780df91b7005b669d41b51170b3b --- Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationGroupContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationGroupContextTreeNodeInfoTest.cs) (revision 01e8d3f7c86b2cc7e52606d71e97bd40431a2b25) +++ Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Plugin.Test/TreeNodeInfos/HeightStructuresCalculationGroupContextTreeNodeInfoTest.cs (.../HeightStructuresCalculationGroupContextTreeNodeInfoTest.cs) (revision 65991df4e411780df91b7005b669d41b51170b3b) @@ -828,7 +828,7 @@ } [Test] - public void ContextMenuStrip_WithForeshoreProfileAndChanges_ContextMenuItemUpdateForeshoreProfilesEnabled() + public void ContextMenuStrip_CalculationGroupWithCalculationWithForeshoreProfileAndInputOutOfSync_ContextMenuItemUpdateForeshoreProfilesEnabledAndToolTipSet() { // Setup var assessmentSectionStub = mocks.Stub(); @@ -840,7 +840,6 @@ ForeshoreProfile = new TestForeshoreProfile() } }; - calculation.InputParameters.UseBreakWater = true; var nodeData = new HeightStructuresCalculationGroupContext( new CalculationGroup @@ -861,6 +860,8 @@ plugin.Gui = guiStub; + calculation.InputParameters.UseBreakWater = true; + // Call using (ContextMenuStrip menu = info.ContextMenuStrip(nodeData, null, treeViewControl)) { @@ -875,7 +876,7 @@ } [Test] - public void GivenCalculationWithForeshoreProfileSet_WhenUpdatingForeshoreProfileFromContextMenu_ThenCalculationInputUpdatedAndObserverNotified() + public void GivenCalculationWithoutOutputAndWithInputOutOfSync_WhenUpdateForeshoreProfilesClicked_ThenNoInquiryAndCalculationUpdatedAndInputObserverNotified() { // Given var calculationObserver = mocks.StrictMock(); @@ -892,7 +893,6 @@ ForeshoreProfile = new TestForeshoreProfile(true) } }; - calculation.InputParameters.UseBreakWater = false; var nodeData = new HeightStructuresCalculationGroupContext( new CalculationGroup @@ -916,6 +916,8 @@ plugin.Gui = guiStub; + calculation.InputParameters.UseBreakWater = false; + using (ContextMenuStrip contextMenuStrip = info.ContextMenuStrip(nodeData, null, treeViewControl)) { // Precondition