コード例 #1
0
        public void ReadProbabilityAssessmentInput_ProbabilityAssessmentInputNull_ThrowsArgumentNullException()
        {
            // Setup
            var entity = new MacroStabilityInwardsFailureMechanismMetaEntity();

            // Call
            TestDelegate test = () => entity.ReadProbabilityAssessmentInput(null);

            // Assert
            var exception = Assert.Throws <ArgumentNullException>(test);

            Assert.AreEqual("probabilityAssessmentInput", exception.ParamName);
        }
コード例 #2
0
        public void ReadProbabilityAssessmentInput_ValidParameters_SetMacroStabilityInwardsProbabilityAssessmentInputProperties()
        {
            // Setup
            var inputToUpdate = new MacroStabilityInwardsProbabilityAssessmentInput();
            var entity        = new MacroStabilityInwardsFailureMechanismMetaEntity
            {
                A = new Random(31).NextDouble()
            };

            // Call
            entity.ReadProbabilityAssessmentInput(inputToUpdate);

            // Assert
            Assert.AreEqual(entity.A, inputToUpdate.A);
        }