예제 #1
0
        public void KmlParser_Strict_Returns_Kml(string kml)
        {
            var options = DefaultOptions(KmlParserMode.Strict);

            var kmlParser = new KmlParser(
                options,
                new PropertyDescriber(options),
                new TypeDescriber(options)
                );

            var result = kmlParser.ParseKml(kml);

            Assert.NotNull(result);
            Assert.IsType <Kml>(result);
        }
예제 #2
0
        public void KmlParser_Strict_Returns_Kml_With_Properties(string kml, Func <Kml, bool> valid)
        {
            var options = DefaultOptions(KmlParserMode.Strict);

            var kmlParser = new KmlParser(
                options,
                new PropertyDescriber(options),
                new TypeDescriber(options)
                );

            var result = kmlParser.ParseKml(kml);

            Assert.NotNull(result);
            Assert.IsType <Kml>(result);
            Assert.True(valid(result));
        }