diff options
author | Victor Stinner <victor.stinner@haypocalc.com> | 2011-05-20 00:29:55 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@haypocalc.com> | 2011-05-20 00:29:55 (GMT) |
commit | ba8ef7a81d5a2ee09713a273c156abf839c7b21b (patch) | |
tree | 42aa248ad50946748f6392fc18e78ef28f77cb63 /Lib/test/test_pydoc.py | |
parent | 4050c69f78a9cfb9b16fe7a1bfae8e9fbda89024 (diff) | |
parent | 62a68f2dbe2c33c57d5840f38105dc11e33a77b7 (diff) | |
download | cpython-ba8ef7a81d5a2ee09713a273c156abf839c7b21b.zip cpython-ba8ef7a81d5a2ee09713a273c156abf839c7b21b.tar.gz cpython-ba8ef7a81d5a2ee09713a273c156abf839c7b21b.tar.bz2 |
(Merge 3.2) test_pydoc: skip PydocServerTest if thread support is disabled
Diffstat (limited to 'Lib/test/test_pydoc.py')
-rw-r--r-- | Lib/test/test_pydoc.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/test/test_pydoc.py b/Lib/test/test_pydoc.py index 6dca0c9..7d17a98 100644 --- a/Lib/test/test_pydoc.py +++ b/Lib/test/test_pydoc.py @@ -20,6 +20,11 @@ from test.support import TESTFN, forget, rmtree, EnvironmentVarGuard, \ from test import pydoc_mod +try: + import threading +except ImportError: + threading = None + # Just in case sys.modules["test"] has the optional attribute __loader__. if hasattr(pydoc_mod, "__loader__"): del pydoc_mod.__loader__ @@ -409,6 +414,7 @@ class TestDescriptions(unittest.TestCase): self.assertIn(expected, pydoc.render_doc(c)) +@unittest.skipUnless(threading, 'Threading required for this test.') class PydocServerTest(unittest.TestCase): """Tests for pydoc._start_server""" |