From: Victor Stinner Date: Sun, 11 Oct 2015 08:10:31 +0000 (+0200) Subject: Close #25367: Fix test_coroutines with no thread support X-Git-Tag: v3.5.1rc1~177 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b45c0f7e4833615067dbe74c1e813fd1b45ce181;p=thirdparty%2FPython%2Fcpython.git Close #25367: Fix test_coroutines with no thread support Skip test_asyncio_1() when the asyncio module cannot be imported because CPython is compiled with no thread support. --- diff --git a/Lib/test/test_coroutines.py b/Lib/test/test_coroutines.py index 10de85644ee4..71fbe8212fbd 100644 --- a/Lib/test/test_coroutines.py +++ b/Lib/test/test_coroutines.py @@ -1322,7 +1322,9 @@ class CoroutineTest(unittest.TestCase): class CoroAsyncIOCompatTest(unittest.TestCase): def test_asyncio_1(self): - import asyncio + # asyncio cannot be imported when Python is compiled without thread + # support + support.import_module('asyncio') class MyException(Exception): pass