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); }
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); }
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); }
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); }