From afa182ab7c48e70e0fe67aa78ecff4bfd9830219 Mon Sep 17 00:00:00 2001 From: Jeremy Fincher Date: Sat, 9 Oct 2004 04:56:50 +0000 Subject: [PATCH] Added another test. --- test/test_irclib.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/test_irclib.py b/test/test_irclib.py index 558ed9e71..51fd435ea 100644 --- a/test/test_irclib.py +++ b/test/test_irclib.py @@ -205,6 +205,14 @@ class IrcStateTestCase(SupyTestCase): nick = 'nick' prefix = 'nick!user@host' irc = FakeIrc() + def testAddMsgRemovesOpsProperly(self): + st = irclib.IrcState() + st.channels['#foo'] = irclib.ChannelState() + st.channels['#foo'].ops.add('bar') + m = ircmsgs.mode('#foo', ('-o', 'bar')) + st.addMsg(self.irc, m) + self.failIf('bar' in st.channels['#foo'].ops) + def testHistory(self): oldconfmaxhistory = conf.supybot.protocols.irc.maxHistoryLength() conf.supybot.protocols.irc.maxHistoryLength.setValue(10)