Esempio n. 1
0
 public void testWithValidInput()
 {
     Assert.AreEqual(0, this.mockBot.Size);
     XmlNode testNode = StaticHelpers.getNode("<learn>./aiml/Salutations.aiml</learn>");
     this.mockBotTagHandler = new AIMLbot.AIMLTagHandlers.learn(this.mockBot, this.mockUser, this.mockQuery, this.mockRequest, this.mockResult, testNode);
     Assert.AreEqual("", this.mockBotTagHandler.Transform());
     Assert.AreEqual(16, this.mockBot.Size);
 }
Esempio n. 2
0
        public void testWithEmptyInput()
        {
            Assert.Equal(0, this.mockBot.Size);
            XmlNode testNode          = getNode("<learn/>");
            var     mockBotTagHandler = new AIMLbot.AIMLTagHandlers.learn(this.mockBot, this.mockUser, this.mockQuery, mockRequest, mockResult, testNode);

            Assert.Equal("", mockBotTagHandler.Transform());
            Assert.Equal(0, this.mockBot.Size);
        }
Esempio n. 3
0
        public void testWithBadInput()
        {
            Assert.Equal(0, this.mockBot.Size);
            XmlNode testNode          = getNode("<learn>./nonexistent/Salutations.aiml</learn>");
            var     mockBotTagHandler = new AIMLbot.AIMLTagHandlers.learn(this.mockBot, this.mockUser, this.mockQuery, mockRequest, mockResult, testNode);

            Assert.Equal("", mockBotTagHandler.Transform());
            Assert.Equal(0, this.mockBot.Size);
        }
Esempio n. 4
0
        public void testWithEmptyInput()
        {

            Assert.AreEqual(0, this.mockBot.Size);
            XmlNode testNode = StaticHelpers.getNode("<learn/>");
            this.mockBotTagHandler = new AIMLbot.AIMLTagHandlers.learn(this.mockBot, this.mockUser, this.mockQuery, this.mockRequest, this.mockResult, testNode);
            Assert.AreEqual("", this.mockBotTagHandler.Transform());
            Assert.AreEqual(0, this.mockBot.Size);
        }
Esempio n. 5
0
        public void testWithValidInput()
        {
            Assert.AreEqual(0, this.mockBot.Size);
            XmlNode testNode = StaticHelpers.getNode("<learn>./aiml/Salutations.aiml</learn>");

            this.mockBotTagHandler = new AIMLbot.AIMLTagHandlers.learn(this.mockBot, this.mockUser, this.mockQuery, this.mockRequest, this.mockResult, testNode);
            Assert.AreEqual("", this.mockBotTagHandler.Transform());
            Assert.AreEqual(16, this.mockBot.Size);
        }