Index: Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultRows/GrassCoverSlipOffOutwardsSectionResultRowTest.cs =================================================================== diff -u -rf4049b9b0967513aeadfddb1fe58efa3b3aa1677 -r8d979ff353df477ff9b31a8c6d859e87703f7dcc --- Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultRows/GrassCoverSlipOffOutwardsSectionResultRowTest.cs (.../GrassCoverSlipOffOutwardsSectionResultRowTest.cs) (revision f4049b9b0967513aeadfddb1fe58efa3b3aa1677) +++ Ringtoets/Integration/test/Ringtoets.Integration.Forms.Test/Views/SectionResultRows/GrassCoverSlipOffOutwardsSectionResultRowTest.cs (.../GrassCoverSlipOffOutwardsSectionResultRowTest.cs) (revision 8d979ff353df477ff9b31a8c6d859e87703f7dcc) @@ -20,9 +20,11 @@ // All rights reserved. using System; +using Core.Common.Base; using Core.Common.Base.Data; using Core.Common.TestUtil; using NUnit.Framework; +using Rhino.Mocks; using Ringtoets.Common.Data.FailureMechanism; using Ringtoets.Common.Data.TestUtil; using Ringtoets.Common.Forms.TypeConverters; @@ -48,6 +50,7 @@ // Assert Assert.IsInstanceOf>(row); + Assert.AreEqual(result.SimpleAssessmentInput, row.SimpleAssessmentResult); Assert.AreEqual(result.AssessmentLayerTwoA, row.AssessmentLayerTwoA); Assert.AreEqual(result.AssessmentLayerThree, row.AssessmentLayerThree); @@ -56,6 +59,32 @@ } [Test] + public void SimpleAssessmentResult_SetNewValue_NotifyObserversAndPropertyChanged() + { + // Setup + var mocks = new MockRepository(); + var observer = mocks.StrictMock(); + observer.Expect(o => o.UpdateObserver()); + mocks.ReplayAll(); + + var random = new Random(39); + var newValue = random.NextEnumValue(); + + FailureMechanismSection section = FailureMechanismSectionTestFactory.CreateFailureMechanismSection(); + var result = new GrassCoverSlipOffOutwardsFailureMechanismSectionResult(section); + result.Attach(observer); + + var row = new GrassCoverSlipOffOutwardsSectionResultRow(result); + + // Call + row.SimpleAssessmentResult = newValue; + + // Assert + Assert.AreEqual(newValue, result.SimpleAssessmentInput); + mocks.VerifyAll(); + } + + [Test] public void AssessmentLayerTwoA_AlwaysOnChange_ResultPropertyChanged() { // Setup