Issue #17041: Fix testing when Python is configured with the

--without-doc-strings.
This commit is contained in:
Serhiy Storchaka 2013-01-27 19:47:45 +02:00
parent 6f02ea02c8
commit 9d0add0c7e
7 changed files with 54 additions and 20 deletions

View file

@ -1477,6 +1477,16 @@ def run_unittest(*classes):
_filter_suite(suite, case_pred)
_run_suite(suite)
#=======================================================================
# Check for the presence of docstrings.
HAVE_DOCSTRINGS = (check_impl_detail(cpython=False) or
sys.platform == 'win32' or
sysconfig.get_config_var('WITH_DOC_STRINGS'))
requires_docstrings = unittest.skipUnless(HAVE_DOCSTRINGS,
"test requires docstrings")
#=======================================================================
# doctest driver.