Index: Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/ViewInfos/DuneLocationsViewInfoTest.cs =================================================================== diff -u -rf74c65d0ad7a4658f8a87a0beace37735b3ce749 -rf3f57a8dfb7adadf9beb7b3916fb535222c56922 --- Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/ViewInfos/DuneLocationsViewInfoTest.cs (.../DuneLocationsViewInfoTest.cs) (revision f74c65d0ad7a4658f8a87a0beace37735b3ce749) +++ Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Plugin.Test/ViewInfos/DuneLocationsViewInfoTest.cs (.../DuneLocationsViewInfoTest.cs) (revision f3f57a8dfb7adadf9beb7b3916fb535222c56922) @@ -50,7 +50,7 @@ public void SetUp() { plugin = new DuneErosionPlugin(); - info = plugin.GetViewInfos().First(tni => tni.ViewType == typeof(DuneLocationsView)); + info = plugin.GetViewInfos().First(tni => tni.ViewType == typeof(DuneLocationCalculationsView)); } [TearDown] @@ -76,7 +76,7 @@ Type viewDataType = info.ViewDataType; // Assert - Assert.AreEqual(typeof(IEnumerable), viewDataType); + Assert.AreEqual(typeof(IEnumerable), viewDataType); } [Test] @@ -107,7 +107,7 @@ var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - var context = new DuneLocationCalculationsContext(new ObservableList(), + var context = new DuneLocationCalculationsContext(new ObservableList(), new DuneErosionFailureMechanism(), assessmentSection); @@ -127,8 +127,8 @@ var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - var context = new DuneLocationCalculationsContext(new ObservableList(), - new DuneErosionFailureMechanism(), + var context = new DuneLocationCalculationsContext(new ObservableList(), + new DuneErosionFailureMechanism(), assessmentSection); // Call @@ -151,8 +151,8 @@ new DuneLocationCalculation(new TestDuneLocation()) }; - var context = new DuneLocationCalculationsContext(duneLocations, - new DuneErosionFailureMechanism(), + var context = new DuneLocationCalculationsContext(duneLocations, + new DuneErosionFailureMechanism(), assessmentSection); // Call @@ -183,7 +183,7 @@ plugin.Activate(); // Call - using (var view = info.CreateInstance(context) as DuneLocationsView) + using (var view = info.CreateInstance(context) as DuneLocationCalculationsView) { // Assert Assert.AreSame(assessmentSection, view.AssessmentSection); @@ -215,10 +215,9 @@ plugin.Gui = gui; plugin.Activate(); - using (var view = new DuneLocationsView(locations, - dl => new DuneLocationCalculation(new TestDuneLocation()), - failureMechanism, - assessmentSection)) + using (var view = new DuneLocationCalculationsView(locations, + failureMechanism, + assessmentSection)) { // Call info.AfterCreate(view, data); @@ -246,10 +245,9 @@ assessmentSection.Stub(a => a.Detach(null)).IgnoreArguments(); mocks.ReplayAll(); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - failureMechanism, - assessmentSection)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + failureMechanism, + assessmentSection)) { // Call bool closeForData = info.CloseForData(view, assessmentSection); @@ -280,10 +278,9 @@ }); mocks.ReplayAll(); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - new DuneErosionFailureMechanism(), - assessmentSectionA)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + new DuneErosionFailureMechanism(), + assessmentSectionA)) { // Call bool closeForData = info.CloseForData(view, assessmentSectionB); @@ -315,10 +312,9 @@ failureMechanism, assessmentSection); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - failureMechanism, - assessmentSection)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + failureMechanism, + assessmentSection)) { // Call bool closeForData = info.CloseForData(view, duneErosionFailureMechanismContext); @@ -353,10 +349,9 @@ new DuneErosionFailureMechanism(), assessmentSectionB); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - new DuneErosionFailureMechanism(), - assessmentSectionA)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + new DuneErosionFailureMechanism(), + assessmentSectionA)) { // Call bool closeForData = info.CloseForData(view, duneErosionFailureMechanismContext); @@ -382,10 +377,9 @@ assessmentSection.Stub(a => a.Detach(null)).IgnoreArguments(); mocks.ReplayAll(); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - new DuneErosionFailureMechanism(), - assessmentSection)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + new DuneErosionFailureMechanism(), + assessmentSection)) { // Call bool closeForData = info.CloseForData(view, new object()); @@ -405,10 +399,9 @@ var assessmentSection = mocks.Stub(); mocks.ReplayAll(); - using (var view = new DuneLocationsView(new ObservableList(), - dl => new DuneLocationCalculation(new TestDuneLocation()), - new DuneErosionFailureMechanism(), - assessmentSection)) + using (var view = new DuneLocationCalculationsView(new ObservableList(), + new DuneErosionFailureMechanism(), + assessmentSection)) { // Call bool closeForData = info.CloseForData(view, new object());