Ejemplo n.º 1
0
        public void GivenNullConfig__TestIsValidConfiguration__ReturnsFalse()
        {
            XmlBuildConfigParser sut = new XmlBuildConfigParser(_fileSystem, null);
            bool actual = sut.TestIsValidConfiguration(null);

            Assert.IsFalse(actual);
        }
Ejemplo n.º 2
0
        public void GivenConfig__TestIsValidConfiguration__IsExpected(string xmlContent, bool expected)
        {
            _mockFileData.TextContents = xmlContent;
            XmlBuildConfigParser sut = new XmlBuildConfigParser(_fileSystem, null);
            bool actual = sut.TestIsValidConfiguration(Path);

            Assert.AreEqual(expected, actual);
        }
Ejemplo n.º 3
0
        public void GivenEmptyConfig__TestIsValidConfiguration__ReturnsFalse()
        {
            const string xml = @"<?xml version=""1.0"" encoding=""UTF-8""?>";

            _mockFileData.TextContents = xml;
            XmlBuildConfigParser sut = new XmlBuildConfigParser(_fileSystem, null);
            bool actual = sut.TestIsValidConfiguration(Path);

            Assert.IsFalse(actual);
        }