public void ToString_Contains_StorageStatus() { // Arrange var expectedString = "Storage Status 1234"; var storageInformation = new Mock<SystemStorageInformation>(); storageInformation.Setup(s => s.ToString()).Returns(expectedString); var object1 = new SystemPerformanceData { StorageStatus = storageInformation.Object }; // Act string result = object1.ToString(); // Assert Assert.IsTrue(result.Contains(expectedString)); }
public void ToString_Contains_ProcessorStatus() { // Arrange var expectedString = "ProzessorStatus 1234"; var processorUtilizationInformation = new Mock<ProcessorUtilizationInformation>(); processorUtilizationInformation.Setup(p => p.ToString()).Returns(expectedString); var object1 = new SystemPerformanceData { ProcessorStatus = processorUtilizationInformation.Object }; // Act string result = object1.ToString(); // Assert Assert.IsTrue(result.Contains(expectedString)); }