summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_import
diff options
context:
space:
mode:
authorHai Shi <shihai1992@gmail.com>2020-05-27 22:10:27 (GMT)
committerGitHub <noreply@github.com>2020-05-27 22:10:27 (GMT)
commite80697d687b610bd7fb9104af905dec8f0bc55a7 (patch)
treec848b98eaec2d959237fda725cf47b059f34b12a /Lib/test/test_import
parent7d80b35af1ee03834ae4af83e920dee89c2bc273 (diff)
downloadcpython-e80697d687b610bd7fb9104af905dec8f0bc55a7.zip
cpython-e80697d687b610bd7fb9104af905dec8f0bc55a7.tar.gz
cpython-e80697d687b610bd7fb9104af905dec8f0bc55a7.tar.bz2
bpo-40275: Adding threading_helper submodule in test.support (GH-20263)
Diffstat (limited to 'Lib/test/test_import')
-rw-r--r--Lib/test/test_import/__init__.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/test/test_import/__init__.py b/Lib/test/test_import/__init__.py
index d50befc..060d145 100644
--- a/Lib/test/test_import/__init__.py
+++ b/Lib/test/test_import/__init__.py
@@ -25,6 +25,7 @@ from test.support import (
unlink, unload, cpython_only, TESTFN_UNENCODABLE,
temp_dir, DirsOnSysPath)
from test.support import script_helper
+from test.support import threading_helper
from test.test_importlib.util import uncache
from types import ModuleType
@@ -459,7 +460,7 @@ class ImportTests(unittest.TestCase):
event = threading.Event()
threads = [threading.Thread(target=run) for x in range(2)]
try:
- with test.support.start_threads(threads, event.set):
+ with threading_helper.start_threads(threads, event.set):
time.sleep(0)
finally:
sys.modules.pop('package', None)