diff -r 754112dc3bbb Lib/test/test_generators.py --- a/Lib/test/test_generators.py Sun Jan 27 20:04:26 2013 +0200 +++ b/Lib/test/test_generators.py Sun Jan 27 20:17:58 2013 +0200 @@ -383,7 +383,8 @@ >>> [s for s in dir(i) if not s.startswith('_')] ['close', 'gi_code', 'gi_frame', 'gi_running', 'send', 'throw'] ->>> print(i.__next__.__doc__) +>>> from test.support import HAVE_DOCSTRINGS +>>> print(i.__next__.__doc__ if HAVE_DOCSTRINGS else 'x.__next__() <==> next(x)') x.__next__() <==> next(x) >>> iter(i) is i True diff -r 754112dc3bbb Lib/test/test_genexps.py --- a/Lib/test/test_genexps.py Sun Jan 27 20:04:26 2013 +0200 +++ b/Lib/test/test_genexps.py Sun Jan 27 20:17:58 2013 +0200 @@ -221,7 +221,8 @@ >>> set(attr for attr in dir(g) if not attr.startswith('__')) >= expected True - >>> print(g.__next__.__doc__) + >>> from test.support import HAVE_DOCSTRINGS + >>> print(g.__next__.__doc__ if HAVE_DOCSTRINGS else 'x.__next__() <==> next(x)') x.__next__() <==> next(x) >>> import types >>> isinstance(g, types.GeneratorType)