Beispiel #1
0
        public void TestXml()
        {
            var xml = @"
<xml>
    <parameters>
        <add name='p1' value='true' />
        <add name='p2' value='falses' />
    </parameters>
</xml>".Replace("'", "\"");

            var cfg = new TestPassInLogger(xml, new TraceLogger());

            Assert.AreEqual(1, cfg.Errors().Length);

            Assert.AreEqual(true, cfg.Parameters.First().Value);
            Assert.AreEqual(false, cfg.Parameters.Last().Value);
        }
Beispiel #2
0
        public void TestXml() {
            var xml = @"
<xml>
    <parameters>
        <add name='p1' value='true' />
        <add name='p2' value='falses' />
    </parameters>
</xml>".Replace("'", "\"");

            var cfg = new TestPassInLogger(xml, new TraceLogger());

            var problems = cfg.Logs();
            Assert.AreEqual(1, problems.Count);

            Assert.AreEqual(true, cfg.Parameters.First().Value);
            Assert.AreEqual(false, cfg.Parameters.Last().Value);

        }