Пример #1
0
        public void BugFixTestMultStr()
        {
            var xml     = GetEmbeddedXml(GetType(), "Resources.spellcheckmultstr.xml");
            var docNode = xml.XPathSelectElement("response/lst[@name='spellcheck']");
            SpellCheckResponseParser parser = new SpellCheckResponseParser();
            var spellChecking = parser.ParseSpellChecking(docNode);

            Assert.IsNotNull(spellChecking);
            //Assert.AreEqual("audit", spellChecking.Collation);
            Assert.AreEqual(2, spellChecking.Collations.Count());
            Assert.AreEqual(2, spellChecking.Count);
        }
Пример #2
0
        public void BugFixTestAllCompact()
        {
            var xml     = GetEmbeddedXml(GetType(), "Resources.spellcheckCompact.xml");
            var docNode = xml.XPathSelectElement("response/lst[@name='spellcheck']");
            SpellCheckResponseParser parser = new SpellCheckResponseParser();
            var spellChecking = parser.ParseSpellChecking(docNode);

            Assert.IsNotNull(spellChecking);
            Assert.AreEqual(2, spellChecking.Collations.Count());
            Assert.AreEqual("dell maxtor", spellChecking.Collation);
            Assert.AreEqual(2, spellChecking.Count);
            Assert.AreEqual(1, spellChecking.First().Suggestions.Count);
        }