aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/test_asyncio/functional.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2021-08-26 15:48:24 +0300
committerGitHub <noreply@github.com>2021-08-26 14:48:24 +0200
commit7dc505b8655b3e48b93a4274dfd26e5856d9c64f (patch)
tree37b7b69b36ba9ee715ecdbc2ea1926927d2eee33 /Lib/test/test_asyncio/functional.py
parent8868d48712aee2b490efaf60bed8dfe9fb14d6b7 (diff)
downloadcpython-7dc505b8655b3e48b93a4274dfd26e5856d9c64f.tar.gz
cpython-7dc505b8655b3e48b93a4274dfd26e5856d9c64f.zip
bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968)
Co-authored-by: Ɓukasz Langa <lukasz@langa.pl>
Diffstat (limited to 'Lib/test/test_asyncio/functional.py')
-rw-r--r--Lib/test/test_asyncio/functional.py5
1 files changed, 0 insertions, 5 deletions
diff --git a/Lib/test/test_asyncio/functional.py b/Lib/test/test_asyncio/functional.py
index 74490a869de..d19c7a612cc 100644
--- a/Lib/test/test_asyncio/functional.py
+++ b/Lib/test/test_asyncio/functional.py
@@ -29,10 +29,6 @@ class FunctionalTestCaseMixin:
self.loop.set_exception_handler(self.loop_exception_handler)
self.__unhandled_exceptions = []
- # Disable `_get_running_loop`.
- self._old_get_running_loop = asyncio.events._get_running_loop
- asyncio.events._get_running_loop = lambda: None
-
def tearDown(self):
try:
self.loop.close()
@@ -43,7 +39,6 @@ class FunctionalTestCaseMixin:
self.fail('unexpected calls to loop.call_exception_handler()')
finally:
- asyncio.events._get_running_loop = self._old_get_running_loop
asyncio.set_event_loop(None)
self.loop = None