Index: Riskeer/Integration/src/Riskeer.Integration.Data/RiskeerProject.cs =================================================================== diff -u -rc36b47c2e1e8cf948767cca33f80ad735f370ad0 -r991f347230a23a879fd6ea458586576c43e5e48b --- Riskeer/Integration/src/Riskeer.Integration.Data/RiskeerProject.cs (.../RiskeerProject.cs) (revision c36b47c2e1e8cf948767cca33f80ad735f370ad0) +++ Riskeer/Integration/src/Riskeer.Integration.Data/RiskeerProject.cs (.../RiskeerProject.cs) (revision 991f347230a23a879fd6ea458586576c43e5e48b) @@ -19,8 +19,6 @@ // Stichting Deltares and remain full property of Stichting Deltares at all times. // All rights reserved. -using System.Collections.Generic; -using System.Linq; using Core.Common.Base; using Core.Common.Base.Data; using Core.Common.Base.Properties; @@ -45,14 +43,12 @@ { Name = name; Description = ""; - - AssessmentSections = new List(); } /// - /// Gets or sets the assessment sections of the . + /// Gets or sets the assessment section of the . /// - public List AssessmentSections { get; } + public AssessmentSection AssessmentSection { get; set; } /// /// Gets or sets the name of the . @@ -99,7 +95,7 @@ return string.Equals(Name, otherProject.Name) && string.Equals(Description, otherProject.Description) - && AssessmentSections.SequenceEqual(otherProject.AssessmentSections); + && AssessmentSection.Equals(otherProject.AssessmentSection); } } } \ No newline at end of file Index: Riskeer/Integration/test/Riskeer.Integration.Data.Test/RiskeerProjectTest.cs =================================================================== diff -u -rc36b47c2e1e8cf948767cca33f80ad735f370ad0 -r991f347230a23a879fd6ea458586576c43e5e48b --- Riskeer/Integration/test/Riskeer.Integration.Data.Test/RiskeerProjectTest.cs (.../RiskeerProjectTest.cs) (revision c36b47c2e1e8cf948767cca33f80ad735f370ad0) +++ Riskeer/Integration/test/Riskeer.Integration.Data.Test/RiskeerProjectTest.cs (.../RiskeerProjectTest.cs) (revision 991f347230a23a879fd6ea458586576c43e5e48b) @@ -43,7 +43,7 @@ Assert.IsInstanceOf(project); Assert.AreEqual("Project", project.Name); Assert.AreEqual("", project.Description); - CollectionAssert.IsEmpty(project.AssessmentSections); + Assert.IsNull(project.AssessmentSection); } [Test] @@ -59,7 +59,7 @@ Assert.IsInstanceOf(project); Assert.AreEqual(someName, project.Name); Assert.AreEqual("", project.Description); - CollectionAssert.IsEmpty(project.AssessmentSections); + Assert.IsNull(project.AssessmentSection); } [Test] @@ -148,16 +148,18 @@ var random = new Random(21); RiskeerProject differentAssessmentSections = CreateProject(); - differentAssessmentSections.AssessmentSections.Add(new AssessmentSection(random.NextEnumValue())); + differentAssessmentSections.AssessmentSection = new AssessmentSection(random.NextEnumValue()); yield return new TestCaseData(differentAssessmentSections) .SetName("AssessmentSections"); } private static RiskeerProject CreateProject() { + var random = new Random(21); return new RiskeerProject("Some name") { - Description = "Some desctiption" + Description = "Some description", + AssessmentSection = new AssessmentSection(random.NextEnumValue()) }; } }