diff --git a/test/test_evaluate/test_docstring.py b/test/test_evaluate/test_docstring.py index 007289f8..269a54cb 100644 --- a/test/test_evaluate/test_docstring.py +++ b/test/test_evaluate/test_docstring.py @@ -6,6 +6,7 @@ from textwrap import dedent import jedi import pytest from ..helpers import unittest +import sys try: import numpydoc # NOQA @@ -21,6 +22,11 @@ except ImportError: else: numpy_unavailable = False +if sys.version_info.major == 2: + # In Python 2 there's an issue with tox/docutils that makes the tests fail, + # Python 2 is soon end-of-life, so just don't support numpydoc for it anymore. + numpydoc_unavailable = True + def test_function_doc(Script): defs = Script("""