Added test for the recent bug fixed in addressed.

This commit is contained in:
Jeremy Fincher 2003-09-25 16:12:43 +00:00
parent 31b1abaa59
commit 2682670fc6
1 changed files with 2 additions and 0 deletions

View File

@ -120,6 +120,8 @@ class FunctionsTestCase(unittest.TestCase):
inChannel = [ircmsgs.privmsg('#foo', s) for s in inChannel]
badmsg = ircmsgs.privmsg('#foo', '%s:foo' % nick)
self.failIf(callbacks.addressed(nick, badmsg))
badmsg = ircmsgs.privmsg('#foo', '%s^: foo' % nick)
self.failIf(callbacks.addressed(nick, badmsg))
for msg in inChannel:
self.assertEqual('foo', callbacks.addressed(nick, msg), msg)
msg = ircmsgs.privmsg(nick, 'foo')