示例#1
0
        public void FindDefaults()
        {
            XmlDocument docSrc = new XmlDocument();

            docSrc.LoadXml(
                "<column label=\"Gloss\"> "
                + "<seq field=\"Senses\" sep=\"$delimiter=commaSpace\"> "
                + "<string field=\"Gloss\" ws=\"$ws=analysis\"/> "
                + "</seq> "
                + "</column>");

            XmlNode source = GetRootNode(docSrc, "column");

            Assert.IsNotNull(source);
            Assert.IsTrue(XmlViewsUtils.HasParam(source));

            string[] paramList = XmlViewsUtils.FindParams(source);
            Assert.AreEqual(2, paramList.Length);
            Assert.AreEqual("$delimiter=commaSpace", paramList[0]);
            Assert.AreEqual("$ws=analysis", paramList[1]);
        }