Ticket #3179: test_irc.py.2.diff

File test_irc.py.2.diff, 880 bytes (added by Craig Nagy, 7 years ago)

Whitespace fixed. Ignore previous diff.

  • words/test/test_irc.py

     
    18791879        self.protocol.privmsg = privmsg
    18801880        self.protocol.irc_NOTICE(
    18811881            'spam', ['#greasyspooncafe', "I don't want any spam!"])
     1882
     1883
     1884class DccChatFactoryTests(unittest.TestCase):
     1885    """
     1886    Tests for L{DccChatFactory}
     1887    """
     1888    def test_buildProtocol(self):
     1889        """
     1890        An instance of the DccChat protocol is returned, which has the factory
     1891        property set to the factory which created it.
     1892        """
     1893        queryData = ('fromUser', None, None)
     1894        f = irc.DccChatFactory(None, queryData)
     1895        p = f.buildProtocol('127.0.0.1')
     1896        self.assertTrue(isinstance(p, irc.DccChat))
     1897        self.assertEqual(p.factory, f)