plugins/Misc/test.py: Add a missing plugin that needs to be loaded. Update some documentation and add a note about why a test is failing.

This commit is contained in:
James Vega 2006-05-05 12:50:13 +00:00
parent 514ddbc74f
commit 48a5f2a4a9

View File

@ -30,8 +30,7 @@
from supybot.test import * from supybot.test import *
class MiscTestCase(ChannelPluginTestCase): class MiscTestCase(ChannelPluginTestCase):
# plugins = ('Misc', 'Utilities', 'Gameknot', 'Anonymous', 'Dict', 'User') plugins = ('Misc', 'Utilities', 'Anonymous', 'Plugin',
plugins = ('Misc', 'Utilities', 'Anonymous',
'Channel', 'Dict', 'User', 'String') 'Channel', 'Dict', 'User', 'String')
def testReplyWhenNotCommand(self): def testReplyWhenNotCommand(self):
try: try:
@ -101,7 +100,7 @@ class MiscTestCase(ChannelPluginTestCase):
self.assertNotError('list misc') self.assertNotError('list misc')
def testListPrivate(self): def testListPrivate(self):
# If Ctcp changes to public, these tests will break. So if # If Anonymous changes to public, these tests will break. So if
# the next assert fails, change the plugin we test for public/private # the next assert fails, change the plugin we test for public/private
# to some other non-public plugin. # to some other non-public plugin.
name = 'Anonymous' name = 'Anonymous'
@ -131,7 +130,9 @@ class MiscTestCase(ChannelPluginTestCase):
self.assertNotError('source') self.assertNotError('source')
def testTell(self): def testTell(self):
m = self.getMsg('tell foo [plugin tell]') # This test fails because the test is seeing us as owner and Misc.tell
# allows the owner to send messages to people the bot hasn't seen.
m = self.getMsg('tell aljsdkfh [plugin tell]')
self.failUnless('let you do' in m.args[1]) self.failUnless('let you do' in m.args[1])
m = self.getMsg('tell #foo [plugin tell]') m = self.getMsg('tell #foo [plugin tell]')
self.failUnless('No need for' in m.args[1]) self.failUnless('No need for' in m.args[1])