Index: Riskeer/Piping/src/Riskeer.Piping.Data/Probabilistic/PartialProbabilisticFaultTreePipingOutput.cs =================================================================== diff -u --- Riskeer/Piping/src/Riskeer.Piping.Data/Probabilistic/PartialProbabilisticFaultTreePipingOutput.cs (revision 0) +++ Riskeer/Piping/src/Riskeer.Piping.Data/Probabilistic/PartialProbabilisticFaultTreePipingOutput.cs (revision 372c0536e064b2a9c624f681fb3f4b46553b32e4) @@ -0,0 +1,41 @@ +// Copyright (C) Stichting Deltares 2019. All rights reserved. +// +// This file is part of Riskeer. +// +// Riskeer is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +// +// All names, logos, and references to "Deltares" are registered trademarks of +// Stichting Deltares and remain full property of Stichting Deltares at all times. +// All rights reserved. + +using Riskeer.Common.Data.IllustrationPoints; + +namespace Riskeer.Piping.Data.Probabilistic +{ + /// + /// This class contains the result of a sub-calculation for a + /// with a on the . + /// + public class PartialProbabilisticFaultTreePipingOutput : PartialProbabilisticPipingOutput + { + /// + /// Creates a new instance of . + /// + /// The reliability of the calculation. + /// The general result of this output with the fault tree illustration points. + public PartialProbabilisticFaultTreePipingOutput( + double reliability, GeneralResult generalResult) + : base(reliability, generalResult) {} + } +} \ No newline at end of file Index: Riskeer/Piping/test/Riskeer.Piping.Data.Test/Probabilistic/PartialProbabilisticFaultTreePipingOutputTest.cs =================================================================== diff -u --- Riskeer/Piping/test/Riskeer.Piping.Data.Test/Probabilistic/PartialProbabilisticFaultTreePipingOutputTest.cs (revision 0) +++ Riskeer/Piping/test/Riskeer.Piping.Data.Test/Probabilistic/PartialProbabilisticFaultTreePipingOutputTest.cs (revision 372c0536e064b2a9c624f681fb3f4b46553b32e4) @@ -0,0 +1,55 @@ +// Copyright (C) Stichting Deltares 2019. All rights reserved. +// +// This file is part of Riskeer. +// +// Riskeer is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +// +// All names, logos, and references to "Deltares" are registered trademarks of +// Stichting Deltares and remain full property of Stichting Deltares at all times. +// All rights reserved. + +using System; +using NUnit.Framework; +using Riskeer.Common.Data.IllustrationPoints; +using Riskeer.Common.Data.TestUtil.IllustrationPoints; +using Riskeer.Piping.Data.Probabilistic; + +namespace Riskeer.Piping.Data.Test.Probabilistic +{ + [TestFixture] + public class PartialProbabilisticFaultTreePipingOutputTest + { + [Test] + [TestCase(true)] + [TestCase(false)] + public void Constructor_ExpectedValues(bool withIllustrationPoints) + { + // Setup + var random = new Random(39); + double reliability = random.NextDouble(); + GeneralResult generalResult = withIllustrationPoints + ? new TestGeneralResultFaultTreeIllustrationPoint() + : null; + + // Call + var partialProbabilisticPipingOutput = new PartialProbabilisticFaultTreePipingOutput(reliability, generalResult); + + // Assert + Assert.IsInstanceOf>(partialProbabilisticPipingOutput); + Assert.AreEqual(reliability, partialProbabilisticPipingOutput.Reliability); + Assert.AreEqual(withIllustrationPoints, partialProbabilisticPipingOutput.HasGeneralResult); + Assert.AreSame(generalResult, partialProbabilisticPipingOutput.GeneralResult); + } + } +} \ No newline at end of file