Seen: fix tests so they pass. fix seen command so it properly accepts nick wildcards.

This commit is contained in:
Daniel Folkinshteyn 2011-04-04 16:30:52 -04:00
parent da5b2b35e2
commit 1b74b8ddf6
3 changed files with 4 additions and 4 deletions

View File

@ -219,10 +219,10 @@ class Seen(callbacks.Plugin):
Returns the last time <nick> was seen and what <nick> was last seen
saying. <channel> is only necessary if the message isn't sent on the
channel itself.
channel itself. <nick> may contain * as a wildcard.
"""
self._seen(irc, channel, name)
seen = wrap(seen, ['channel', 'nick'])
seen = wrap(seen, ['channel', 'something'])
def any(self, irc, msg, args, channel, optlist, name):
"""[<channel>] [--user <name>] [<nick>]

View File

@ -50,7 +50,7 @@ class ChannelDBTestCase(ChannelPluginTestCase):
self.assertNotRegexp('seen asldfkjasdlfkj', 'KeyError')
def testAny(self):
self.assertRegexp('seen any', 'test has joined')
self.assertRegexp('seen any', 'test <test!user@host.domain.tld> has joined')
self.irc.feedMsg(ircmsgs.mode(self.channel, args=('+o', self.nick),
prefix=self.prefix))
self.assertRegexp('seen any %s' % self.nick,

View File

@ -1,3 +1,3 @@
"""stick the various versioning attributes in here, so we only have to change
them once."""
version = '0.83.4.1+gribble (2011-03-13T14:21:46-0400)'
version = '0.83.4.1+gribble (2011-04-04T16:30:52-0400)'