skip multiprocessing main handling test when Python is built without threads

This commit is contained in:
Christian Heimes 2013-12-21 15:47:24 +01:00
parent a960599be5
commit 5255b86fba
1 changed files with 2 additions and 0 deletions

View File

@ -15,6 +15,8 @@ from test.script_helper import (
assert_python_ok, assert_python_failure, temp_dir, assert_python_ok, assert_python_failure, temp_dir,
spawn_python, kill_python) spawn_python, kill_python)
# Skip tests if _multiprocessing wasn't built.
_multiprocessing = support.import_module('_multiprocessing')
# Look up which start methods are available to test # Look up which start methods are available to test
import multiprocessing import multiprocessing
AVAILABLE_START_METHODS = set(multiprocessing.get_all_start_methods()) AVAILABLE_START_METHODS = set(multiprocessing.get_all_start_methods())