public void ReadGeneralPipingInput_GeneralPipingInputNull_ThrowsArgumentNullException() { // Setup var entity = new PipingFailureMechanismMetaEntity(); // Call void Call() => entity.ReadGeneralPipingInput(null); // Assert var exception = Assert.Throws <ArgumentNullException>(Call); Assert.AreEqual("generalPipingInput", exception.ParamName); }
public void ReadGeneralPipingInput_ValidParameters_SetGeneralPipingInputWithProperties() { // Setup var inputToUpdate = new GeneralPipingInput(); var entity = new PipingFailureMechanismMetaEntity { WaterVolumetricWeight = new Random(31).NextDouble() }; // Call entity.ReadGeneralPipingInput(inputToUpdate); // Assert Assert.AreEqual(entity.WaterVolumetricWeight, inputToUpdate.WaterVolumetricWeight, inputToUpdate.WaterVolumetricWeight.GetAccuracy()); }