public void LogLineProjectData_CopyConstructor_OtherIsNull_Test() { // Act var copy = new LogLineProjectData(null); // Assert Assert.AreEqual(0, copy.ProjectID); Assert.AreEqual(0, copy.ProjectRun); Assert.AreEqual(0, copy.ProjectClone); Assert.AreEqual(0, copy.ProjectGen); }
/// <summary> /// Initializes a new instance of the <see cref="LogLineProjectData"/> class. /// </summary> /// <param name="other">The other instance from which data will be copied.</param> public LogLineProjectData(LogLineProjectData other) { if (other == null) { return; } ProjectID = other.ProjectID; ProjectRun = other.ProjectRun; ProjectClone = other.ProjectClone; ProjectGen = other.ProjectGen; }
public void LogLineProjectData_CopyConstructor_Test() { // Arrange var data = new LogLineProjectData(1, 2, 3, 4); // Act var copy = new LogLineProjectData(data); // Assert Assert.AreEqual(data.ProjectID, copy.ProjectID); Assert.AreEqual(data.ProjectRun, copy.ProjectRun); Assert.AreEqual(data.ProjectClone, copy.ProjectClone); Assert.AreEqual(data.ProjectGen, copy.ProjectGen); }