diff --git a/Lib/test/test_asyncgen.py b/Lib/test/test_asyncgen.py index 41b1b4f4b48..c24fbea5b09 100644 --- a/Lib/test/test_asyncgen.py +++ b/Lib/test/test_asyncgen.py @@ -1,4 +1,3 @@ -import asyncio import inspect import sys import types @@ -6,6 +5,9 @@ import unittest from unittest import mock +from test.support import import_module +asyncio = import_module("asyncio") + class AwaitException(Exception): pass diff --git a/Lib/test/test_logging.py b/Lib/test/test_logging.py index e45a982dbf7..078a86b359a 100644 --- a/Lib/test/test_logging.py +++ b/Lib/test/test_logging.py @@ -4304,7 +4304,7 @@ class MiscTestCase(unittest.TestCase): 'logProcesses', 'currentframe', 'PercentStyle', 'StrFormatStyle', 'StringTemplateStyle', 'Filterer', 'PlaceHolder', 'Manager', 'RootLogger', - 'root'} + 'root', 'threading'} support.check__all__(self, logging, blacklist=blacklist)