Index: Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/TreeNodeInfos/ReferenceLineContextTreeNodeInfoTest.cs =================================================================== diff -u -r409f425c74884ec6cbd5f56ceb89111dfa2394b5 -r1cc4182b92d9c55afdf6a6805ea9b9a96b6fdb76 --- Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/TreeNodeInfos/ReferenceLineContextTreeNodeInfoTest.cs (.../ReferenceLineContextTreeNodeInfoTest.cs) (revision 409f425c74884ec6cbd5f56ceb89111dfa2394b5) +++ Ringtoets/Integration/test/Ringtoets.Integration.Plugin.Test/TreeNodeInfos/ReferenceLineContextTreeNodeInfoTest.cs (.../ReferenceLineContextTreeNodeInfoTest.cs) (revision 1cc4182b92d9c55afdf6a6805ea9b9a96b6fdb76) @@ -1,4 +1,4 @@ -// Copyright (C) Stichting Deltares 2017. All rights reserved. +// Copyright (C) Stichting Deltares 2018. All rights reserved. // // This file is part of Ringtoets. // @@ -28,7 +28,9 @@ using NUnit.Framework; using Rhino.Mocks; using Ringtoets.Common.Data.AssessmentSection; +using Ringtoets.Common.Data.TestUtil; using Ringtoets.Common.Forms.PresentationObjects; +using Riskeer.Integration.Plugin; using RingtoetsCommonFormsResources = Ringtoets.Common.Forms.Properties.Resources; namespace Ringtoets.Integration.Plugin.Test.TreeNodeInfos @@ -67,7 +69,7 @@ Assert.IsNull(info.CanRemove); Assert.IsNull(info.OnNodeRemoved); Assert.IsNull(info.CanCheck); - Assert.IsNull(info.IsChecked); + Assert.IsNull(info.CheckedState); Assert.IsNull(info.OnNodeChecked); Assert.IsNull(info.CanDrag); Assert.IsNull(info.CanDrop); @@ -85,14 +87,14 @@ var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - var referenceLineContext = new ReferenceLineContext(assessmentSection); + var context = new ReferenceLineContext(new ReferenceLine(), assessmentSection); using (var plugin = new RingtoetsPlugin()) { TreeNodeInfo info = GetInfo(plugin); // Call - string text = info.Text(referenceLineContext); + string text = info.Text(context); // Assert Assert.AreEqual("Referentielijn", text); @@ -108,14 +110,14 @@ var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - var referenceLineContext = new ReferenceLineContext(assessmentSection); + var context = new ReferenceLineContext(new ReferenceLine(), assessmentSection); using (var plugin = new RingtoetsPlugin()) { TreeNodeInfo info = GetInfo(plugin); // Call - Image image = info.Image(referenceLineContext); + Image image = info.Image(context); // Assert TestHelper.AssertImagesAreEqual(RingtoetsCommonFormsResources.ReferenceLineIcon, image); @@ -159,13 +161,13 @@ } [Test] - public void ForeColor_ContextHasNoReferenceLine_ReturnDisabledColor() + public void ForeColor_ContextHasReferenceLineWithoutGeometry_ReturnDisabledColor() { // Setup var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - var referenceLineContext = new ReferenceLineContext(assessmentSection); + var referenceLineContext = new ReferenceLineContext(new ReferenceLine(), assessmentSection); using (var plugin = new RingtoetsPlugin()) { @@ -182,14 +184,14 @@ } [Test] - public void ForeColor_ContextHasReferenceLineData_ReturnControlText() + public void ForeColor_ContextHasReferenceLineWithGeometry_ReturnControlText() { // Setup var assessmentSection = mocks.Stub(); - assessmentSection.ReferenceLine = new ReferenceLine(); mocks.ReplayAll(); - var referenceLineContext = new ReferenceLineContext(assessmentSection); + var referenceLineContext = new ReferenceLineContext(ReferenceLineTestFactory.CreateReferenceLineWithGeometry(), + assessmentSection); using (var plugin = new RingtoetsPlugin()) {