Пример #1
0
    def test_process_create_warning(self):
        proto = subprocess.SubprocessStreamProtocol(limit=10, loop=self.loop,
                                                    _asyncio_internal=True)
        transp = mock.Mock()

        with self.assertWarns(DeprecationWarning):
            subprocess.Process(transp, proto, loop=self.loop)
Пример #2
0
 def test_subprocess_protocol_create_warning(self):
     with self.assertWarns(DeprecationWarning):
         subprocess.SubprocessStreamProtocol(limit=10, loop=self.loop)
Пример #3
0
 def protocol_factory():
     return subprocess.SubprocessStreamProtocol(
         loop=loop, limit=DEFAULT_LIMIT)