From 1ad9816391d15ea8c6fa69b7a2f73b4f83fe6394 Mon Sep 17 00:00:00 2001 From: Jeremy Fincher Date: Fri, 27 Aug 2004 15:44:15 +0000 Subject: [PATCH] Tests for karma/infobot interaction. --- test/test_Infobot.py | 5 ++++- test/test_Karma.py | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/test/test_Infobot.py b/test/test_Infobot.py index 3ce1eb0cd..7c30c3bfe 100644 --- a/test/test_Infobot.py +++ b/test/test_Infobot.py @@ -43,7 +43,7 @@ if sqlite is not None: ibot = conf.supybot.plugins.Infobot class InfobotTestCase(ChannelPluginTestCase): - plugins = ('Infobot',) + plugins = ('Infobot', 'Karma') _endRe = re.compile(r'!|, \S+\.|\.') def testIsSnarf(self): learn = ibot.snarfUnaddressedDefinitions() @@ -136,4 +136,7 @@ if sqlite is not None: ibot.answerUnaddressedQuestions.setValue(answer) ibot.snarfUnaddressedDefinitions.setValue(learn) + def testNoKarmaDunno(self): + self.assertNoResponse('foo++') + # vim:set shiftwidth=4 tabstop=8 expandtab textwidth=78: diff --git a/test/test_Karma.py b/test/test_Karma.py index a40adb266..6c1f0e325 100644 --- a/test/test_Karma.py +++ b/test/test_Karma.py @@ -186,6 +186,9 @@ if sqlite is not None: self.assertRegexp('karma foo', '0') self.assertNotRegexp('karma foo', '1') + def testNoKarmaDunno(self): + self.assertNotError('load Infobot') + self.assertNoResponse('foo++') # vim:set shiftwidth=4 tabstop=8 expandtab textwidth=78: