def test_deferredOnNotInitialized(self):

        class TestException(Exception):
            pass

        xs = self.factory.buildProtocol(None)
        xs.dispatch(TestException(), INIT_FAILED_EVENT)
        self.assertFailure(self.factory.deferred, TestException)
        return self.factory.deferred
Test the factory's deferred on failed stream initialization.
dataset/ETHPy150Open ralphm/wokkel/wokkel/test/test_client.py/DeferredClientFactoryTest.test_deferredOnNotInitialized