def test_connectionFailedCallsStopListening(self):
        self.called = False

        def stopListening():
            """
            Dummy C{stopListening} method.
            """
            self.called = True

        port = unix.ConnectedDatagramPort(None, ClientProto())
        port.stopListening = stopListening
        port.connectionFailed("goodbye")
        self.assertEquals(self.called, True)
L{ConnectedDatagramPort} calls L{ConnectedDatagramPort.stopListening}
dataset/ETHPy150Open kuri65536/python-for-android/python-modules/twisted/twisted/internet/test/test_posixbase.py/ConnectedDatagramPortTestCase.test_connectionFailedCallsStopListening