public void ArmaConfigDebinarizer_ValidFile_DebinarizesFileAndSavesCorrectly() { //Arrange File.WriteAllBytes(_configFilePath, Resources.test_vars); //Act _configDebinarizer.DebinarizeConfigFile(_configFilePath, _debinarizedFilePath); //Assert FileAssert.Exists(_debinarizedFilePath); Assert.AreEqual(432973, File.ReadAllLines(_debinarizedFilePath).Length); }
public void DebinarizeConfigFile_EmptySourcePath_ThrowsException() { //Arrange _fileWrapper.Setup(x => x.Exists(It.IsAny <string>())).Returns(true); //Act/Assert Assert.Throws <ArgumentException>(() => _configDebinarizer.DebinarizeConfigFile(string.Empty, @"C:\CoolPath\debinarized.cpp")); }