Esempio n. 1
0
        public void ToString_Contains_FreeDiscSpaceInPercent()
        {
            // Arrange
            var object1 = new SystemStorageDeviceInformation {
                DeviceName = "C:", FreeDiscSpaceInPercent = 30.0d
            };

            // Act
            string result = object1.ToString();

            // Assert
            Assert.IsTrue(result.Contains(object1.FreeDiscSpaceInPercent.ToString()));
        }
Esempio n. 2
0
        public void ToString_Contains_AvailableMemoryInGB()
        {
            // Arrange
            var entry1  = new SystemStorageDeviceInformation();
            var object1 = new SystemStorageInformation {
                StorageDeviceInfos = new[] { entry1 }
            };

            // Act
            string result = object1.ToString();

            // Assert
            Assert.IsTrue(result.Contains(entry1.ToString()));
        }