]> granicus.if.org Git - python/commitdiff
skip multiprocessing main handling test when Python is built without threads
authorChristian Heimes <christian@cheimes.de>
Sat, 21 Dec 2013 14:47:24 +0000 (15:47 +0100)
committerChristian Heimes <christian@cheimes.de>
Sat, 21 Dec 2013 14:47:24 +0000 (15:47 +0100)
Lib/test/test_multiprocessing_main_handling.py

index e4442d20e01677ea3ddf0e26a2c3242e5c0d7474..aa85a4d1e0f74cbfcffa0fc5cc4af7ae587fd69c 100644 (file)
@@ -15,6 +15,8 @@ from test.script_helper import (
     assert_python_ok, assert_python_failure, temp_dir,
     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
 import multiprocessing
 AVAILABLE_START_METHODS = set(multiprocessing.get_all_start_methods())