def test_reprWithNewStyleFactory(self):
"""
The two string representations of the L{IListeningPort} returned by
L{IReactorUNIX.listenUNIX} contains the name of the new-style factory
class being used and the filename on which the port is listening or
indicates that the port is not listening.
"""
class NewStyleFactory(object):
def doStart(self):
pass
def doStop(self):
pass
# Sanity check
self.assertIsInstance(NewStyleFactory, type)
return self._reprTest(
NewStyleFactory(), "twisted.test.test_unix.NewStyleFactory")
评论列表
文章目录