[Python-checkins] cpython (3.3): Fix test_pydoc for build --without-doc-strings.

stefan.krah python-checkins at python.org
Sat Jan 26 13:58:48 CET 2013


http://hg.python.org/cpython/rev/9a98ab22ab95
changeset: 81758:9a98ab22ab95
branch: 3.3
parent: 81755:5c7f92bfe785
user: Stefan Krah <skrah at bytereef.org>
date: Sat Jan 26 13:57:15 2013 +0100
summary:
 Fix test_pydoc for build --without-doc-strings.
files:
 Lib/test/test_pydoc.py | 4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/Lib/test/test_pydoc.py b/Lib/test/test_pydoc.py
--- a/Lib/test/test_pydoc.py
+++ b/Lib/test/test_pydoc.py
@@ -256,6 +256,7 @@
 "Docstrings are omitted with -O2 and above")
 @unittest.skipIf(hasattr(sys, 'gettrace') and sys.gettrace(),
 'trace function introduces __locals__ unexpectedly')
+ @test.support.requires_docstrings
 def test_html_doc(self):
 result, doc_loc = get_pydoc_html(pydoc_mod)
 mod_file = inspect.getabsfile(pydoc_mod)
@@ -273,6 +274,7 @@
 "Docstrings are omitted with -O2 and above")
 @unittest.skipIf(hasattr(sys, 'gettrace') and sys.gettrace(),
 'trace function introduces __locals__ unexpectedly')
+ @test.support.requires_docstrings
 def test_text_doc(self):
 result, doc_loc = get_pydoc_text(pydoc_mod)
 expected_text = expected_text_pattern % \
@@ -327,6 +329,7 @@
 'Docstrings are omitted with -O2 and above')
 @unittest.skipIf(hasattr(sys, 'gettrace') and sys.gettrace(),
 'trace function introduces __locals__ unexpectedly')
+ @test.support.requires_docstrings
 def test_help_output_redirect(self):
 # issue 940286, if output is set in Helper, then all output from
 # Helper.help should be redirected
@@ -496,6 +499,7 @@
 self.assertRaises(TypeError, f, 'A', '')
 self.assertRaises(TypeError, f, 'B', 'foobar')
 
+ @test.support.requires_docstrings
 def test_url_requests(self):
 # Test for the correct title in the html pages returned.
 # This tests the different parts of the URL handler without
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /