This commit is contained in:
Jeremy Fincher 2004-08-23 16:16:53 +00:00
parent b3ca5ed568
commit fae870c04f

View File

@ -57,15 +57,12 @@ class FunctionsTestCase(SupyTestCase):
int(s) int(s)
except ValueError: except ValueError:
self.fail('$randomint wasn\'t an int.') self.fail('$randomint wasn\'t an int.')
self.assertEqual(f(self.irc, msg, '$botnick'), self.assertEqual(f(self.irc, msg, '$botnick'), self.irc.nick)
self.irc.nick) self.assertEqual(f(self.irc, msg, '$who'), msg.nick)
self.assertEqual(f(self.irc, msg, '$who'),
msg.nick)
self.assertEqual(f(self.irc, msg, '$WHO'), self.assertEqual(f(self.irc, msg, '$WHO'),
msg.nick, 'stand. sub. not case-insensitive.') msg.nick, 'stand. sub. not case-insensitive.')
self.assertEqual(f(self.irc, msg, '$nick'), self.assertEqual(f(self.irc, msg, '$nick'), msg.nick)
msg.nick) self.assertNotEqual(f(self.irc, msg, '$randomdate'), '$randomdate')
self.assert_(f(self.irc, msg, '$randomdate'))
q = f(self.irc,msg,'$randomdate\t$randomdate') q = f(self.irc,msg,'$randomdate\t$randomdate')
dl = q.split('\t') dl = q.split('\t')
if dl[0] == dl[1]: if dl[0] == dl[1]: