Index: Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/SectionResultViews/MacroStabilityOutwardsResultView.cs =================================================================== diff -u -r6964a11e5853dcd0569c54b186f91d0eb9cbf840 -rd08ab1ae8e6befe9ba2e16fdb9264cd5dbc6d8ad --- Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/SectionResultViews/MacroStabilityOutwardsResultView.cs (.../MacroStabilityOutwardsResultView.cs) (revision 6964a11e5853dcd0569c54b186f91d0eb9cbf840) +++ Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/SectionResultViews/MacroStabilityOutwardsResultView.cs (.../MacroStabilityOutwardsResultView.cs) (revision d08ab1ae8e6befe9ba2e16fdb9264cd5dbc6d8ad) @@ -44,6 +44,7 @@ private const int detailedAssessmentProbabilityIndex = 3; private const int tailorMadeAssessmentResultIndex = 4; private const int tailorMadeAssessmentProbabilityIndex = 5; + private const int manualAssemblyCategoryGroupIndex = 11; private readonly IAssessmentSection assessmentSection; @@ -149,7 +150,13 @@ { tailorMadeAssessmentProbabilityIndex }, - row => row.TailorMadeAssessmentResult != TailorMadeAssessmentResultType.Probability) + row => row.TailorMadeAssessmentResult != TailorMadeAssessmentResultType.Probability), + new DataGridViewColumnFormattingRule( + new [] + { + manualAssemblyCategoryGroupIndex + }, + row => !row.UseManualAssemblyCategoryGroup), }; } } Index: Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultViews/MacrostabilityOutwardsResultViewTest.cs =================================================================== diff -u -r6964a11e5853dcd0569c54b186f91d0eb9cbf840 -rd08ab1ae8e6befe9ba2e16fdb9264cd5dbc6d8ad --- Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultViews/MacrostabilityOutwardsResultViewTest.cs (.../MacrostabilityOutwardsResultViewTest.cs) (revision 6964a11e5853dcd0569c54b186f91d0eb9cbf840) +++ Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultViews/MacrostabilityOutwardsResultViewTest.cs (.../MacrostabilityOutwardsResultViewTest.cs) (revision d08ab1ae8e6befe9ba2e16fdb9264cd5dbc6d8ad) @@ -337,5 +337,44 @@ mocks.VerifyAll(); } } + + [Test] + [TestCase(true)] + [TestCase(false)] + public void FailureMechanismResultView_UseManualAssemblyCategoryGroupSet_CellDisabledEnabled(bool useManualAssemblyCategoryGroup) + { + // Setup + var mocks = new MockRepository(); + var assessmentSection = mocks.Stub(); + mocks.ReplayAll(); + + var result = new MacroStabilityOutwardsFailureMechanismSectionResult( + FailureMechanismSectionTestFactory.CreateFailureMechanismSection()) + { + UseManualAssemblyCategoryGroup = useManualAssemblyCategoryGroup + }; + var sectionResults = new ObservableList + { + result + }; + + // Call + using (var form = new Form()) + using (var view = new MacroStabilityOutwardsResultView(sectionResults, new MacroStabilityOutwardsFailureMechanism(), assessmentSection)) + { + form.Controls.Add(view); + form.Show(); + + var dataGridView = (DataGridView)new ControlTester("dataGridView").TheObject; + DataGridViewCellCollection cells = dataGridView.Rows[0].Cells; + + // Assert + DataGridViewTestHelper.AssertCellsState(cells, new[] + { + manualAssemblyCategoryGroupIndex + }, useManualAssemblyCategoryGroup); + mocks.VerifyAll(); + } + } } } \ No newline at end of file