Made $nick the same as $who.

This commit is contained in:
Jeremy Fincher 2003-11-13 18:38:52 +00:00
parent d496328e81
commit 7b86dfb195
2 changed files with 3 additions and 1 deletions

View File

@ -337,7 +337,7 @@ _randomnickRe = re.compile(r'\$randomnick', re.I)
_randomdateRe = re.compile(r'\$randomdate', re.I) _randomdateRe = re.compile(r'\$randomdate', re.I)
_randomintRe = re.compile(r'\$randomint', re.I) _randomintRe = re.compile(r'\$randomint', re.I)
_channelRe = re.compile(r'\$channel', re.I) _channelRe = re.compile(r'\$channel', re.I)
_whoRe = re.compile(r'\$who', re.I) _whoRe = re.compile(r'\$(?:who|nick)', re.I)
_botnickRe = re.compile(r'\$botnick', re.I) _botnickRe = re.compile(r'\$botnick', re.I)
_todayRe = re.compile(r'\$today', re.I) _todayRe = re.compile(r'\$today', re.I)
_nowRe = re.compile(r'\$now', re.I) _nowRe = re.compile(r'\$now', re.I)

View File

@ -74,6 +74,8 @@ class FunctionsTestCase(unittest.TestCase):
self.irc.nick) self.irc.nick)
self.assertEqual(plugins.standardSubstitute(self.irc, msg, '$who'), self.assertEqual(plugins.standardSubstitute(self.irc, msg, '$who'),
msg.nick) msg.nick)
self.assertEqual(plugins.standardSubstitute(self.irc, msg, '$nick'),
msg.nick)
self.assert_(plugins.standardSubstitute(self.irc, msg, '$randomdate')) self.assert_(plugins.standardSubstitute(self.irc, msg, '$randomdate'))
q = plugins.standardSubstitute(self.irc,msg,'$randomdate\t$randomdate') q = plugins.standardSubstitute(self.irc,msg,'$randomdate\t$randomdate')
dl = q.split('\t') dl = q.split('\t')