Fixed a bugger in Misc.py.

This commit is contained in:
Jeremy Fincher 2003-10-24 21:59:49 +00:00
parent a666eddd16
commit 5ddd26cc69
2 changed files with 7 additions and 2 deletions

View File

@ -98,7 +98,7 @@ class Misc(callbacks.Privmsg):
'Please specify the plugin whose command you ' \ 'Please specify the plugin whose command you ' \
'wish to call by using its name as a command ' \ 'wish to call by using its name as a command ' \
'before calling it.' % \ 'before calling it.' % \
(command, utils.commaAndify(names), command) (command, utils.commaAndify(names))
else: else:
L = [] L = []
while ambiguousCommands: while ambiguousCommands:

View File

@ -241,6 +241,11 @@ class PrivmsgTestCase(ChannelPluginTestCase):
self.assertResponse('first firstcmd', 'foo') self.assertResponse('first firstcmd', 'foo')
self.assertResponse('firstrepeat firstcmd', 'baz') self.assertResponse('firstrepeat firstcmd', 'baz')
def testAmbiguousHelpError(self):
self.irc.addCallback(self.First())
self.irc.addCallback(self.FirstRepeat())
self.assertError('help first')
def testHelpDispatching(self): def testHelpDispatching(self):
self.irc.addCallback(self.First()) self.irc.addCallback(self.First())
self.assertHelp('help firstcmd') self.assertHelp('help firstcmd')
@ -280,7 +285,7 @@ class PrivmsgCommandAndRegexpTestCase(PluginTestCase):
raise callbacks.ArgumentError raise callbacks.ArgumentError
def testNoEscapingArgumentError(self): def testNoEscapingArgumentError(self):
self.irc.addCallback(self.PCAR()) self.irc.addCallback(self.PCAR())
self.assertResponse('test', 'PCAR test <foo>') self.assertResponse('test', 'test <foo>')
# vim:set shiftwidth=4 tabstop=8 expandtab textwidth=78: # vim:set shiftwidth=4 tabstop=8 expandtab textwidth=78: