Index: Ringtoets/Integration/test/Ringtoets.Integration.IO.Test/Assembly/ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssemblyTest.cs =================================================================== diff -u -rc92cbdd379cb7fccfd80a39507b064cbfba180a1 -r2ef6b37ec24f65fd5a00c7c1d9d1e9371579bebb --- Ringtoets/Integration/test/Ringtoets.Integration.IO.Test/Assembly/ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssemblyTest.cs (.../ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssemblyTest.cs) (revision c92cbdd379cb7fccfd80a39507b064cbfba180a1) +++ Ringtoets/Integration/test/Ringtoets.Integration.IO.Test/Assembly/ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssemblyTest.cs (.../ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssemblyTest.cs) (revision 2ef6b37ec24f65fd5a00c7c1d9d1e9371579bebb) @@ -1,7 +1,5 @@ using System; -using Core.Common.TestUtil; using NUnit.Framework; -using Ringtoets.AssemblyTool.Data; using Ringtoets.Integration.IO.Assembly; using Ringtoets.Integration.IO.TestUtil; @@ -17,8 +15,8 @@ TestDelegate call = () => new ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssembly( ExportableFailureMechanismSectionTestFactory.CreatExportableFailureMechanismSection(), null, - CreateSectionResult(), - CreateSectionResult()); + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(), + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult()); // Assert var exception = Assert.Throws(call); @@ -31,9 +29,9 @@ // Call TestDelegate call = () => new ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssembly( ExportableFailureMechanismSectionTestFactory.CreatExportableFailureMechanismSection(), - CreateSectionResult(), + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(), null, - CreateSectionResult()); + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult()); // Assert var exception = Assert.Throws(call); @@ -46,8 +44,8 @@ // Call TestDelegate call = () => new ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssembly( ExportableFailureMechanismSectionTestFactory.CreatExportableFailureMechanismSection(), - CreateSectionResult(), - CreateSectionResult(), + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(), + ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(), null); // Assert @@ -60,9 +58,9 @@ { // Setup ExportableFailureMechanismSection failureMechanismSection = ExportableFailureMechanismSectionTestFactory.CreatExportableFailureMechanismSection(); - ExportableSectionAssemblyResult simpleAssembly = CreateSectionResult(); - ExportableSectionAssemblyResult tailorMadeAssembly = CreateSectionResult(); - ExportableSectionAssemblyResult combinedAssembly = CreateSectionResult(); + ExportableSectionAssemblyResult simpleAssembly = ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(); + ExportableSectionAssemblyResult tailorMadeAssembly = ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(); + ExportableSectionAssemblyResult combinedAssembly = ExportableSectionAssemblyResultTestFactory.CreateSectionAssemblyResult(); // Call var assemblyResult = new ExportableAggregatedFailureMechanismSectionAssemblyResultWithoutDetailedAssembly(failureMechanismSection, @@ -78,12 +76,5 @@ Assert.AreSame(tailorMadeAssembly, assemblyResult.TailorMadeAssembly); Assert.AreSame(combinedAssembly, assemblyResult.CombinedAssembly); } - - private static ExportableSectionAssemblyResult CreateSectionResult() - { - var random = new Random(21); - return new ExportableSectionAssemblyResult(random.NextEnumValue(), - random.NextEnumValue()); - } } } \ No newline at end of file