Update tests again

This commit is contained in:
nyuszika7h 2015-01-19 18:08:15 +01:00
parent 5653e0c727
commit c565af7765

View File

@ -387,6 +387,10 @@ class IrcTestCase(SupyTestCase):
m = self.irc.takeMsg() m = self.irc.takeMsg()
self.failUnless(m.command == 'CAP', 'Expected CAP, got %r.' % m) self.failUnless(m.command == 'CAP', 'Expected CAP, got %r.' % m)
m = self.irc.takeMsg() m = self.irc.takeMsg()
self.failUnless(m.command == 'CAP', 'Expected CAP, got %r.' % m)
m = self.irc.takeMsg()
self.failUnless(m.command == 'CAP', 'Expected CAP, got %r.' % m)
m = self.irc.takeMsg()
self.failUnless(m.command == 'USER', 'Expected USER, got %r.' % m) self.failUnless(m.command == 'USER', 'Expected USER, got %r.' % m)
def testPingResponse(self): def testPingResponse(self):
@ -483,11 +487,14 @@ class IrcCallbackTestCase(SupyTestCase):
conf.supybot.nick.setValue(nick) conf.supybot.nick.setValue(nick)
user = 'user any user' user = 'user any user'
conf.supybot.user.setValue(user) conf.supybot.user.setValue(user)
expected = [ircmsgs.nick(nick), expected = [
ircmsgs.IrcMsg(command='CAP', args=('REQ', ircmsgs.nick(nick),
'account-notify extended-join multi-prefix')), ircmsgs.IrcMsg(command='CAP', args=('REQ', 'account-notify')),
ircmsgs.IrcMsg(command='CAP', args=('END',)), ircmsgs.IrcMsg(command='CAP', args=('REQ', 'extended-join')),
ircmsgs.user('limnoria', user)] ircmsgs.IrcMsg(command='CAP', args=('REQ', 'multi-prefix')),
ircmsgs.IrcMsg(command='CAP', args=('END',)),
ircmsgs.user('limnoria', user)
]
irc = irclib.Irc('test') irc = irclib.Irc('test')
msgs = [irc.takeMsg()] msgs = [irc.takeMsg()]
while msgs[-1] != None: while msgs[-1] != None: