|
18 | 18 | import sphinx
|
19 | 19 | from distutils.version import LooseVersion
|
20 | 20 |
|
| 21 | +import pytest_doctestplus.sphinx.doctestplus |
| 22 | + |
21 | 23 | try:
|
22 | 24 | import astropy
|
23 | 25 | except ImportError:
|
@@ -199,31 +201,21 @@ def check_sphinx_version(expected_version):
|
199 | 201 | # Add any Sphinx extension module names here, as strings. They can be
|
200 | 202 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
201 | 203 | # ones.
|
202 |
| -extensions = [ |
203 |
| - 'sphinx_astropy.ext.intersphinx_toggle', |
204 |
| - 'sphinx.ext.autodoc', |
205 |
| - 'sphinx.ext.intersphinx', |
206 |
| - 'sphinx.ext.todo', |
207 |
| - 'sphinx.ext.coverage', |
208 |
| - 'sphinx.ext.inheritance_diagram', |
209 |
| - 'sphinx.ext.viewcode', |
210 |
| - 'numpydoc', |
211 |
| - 'sphinx_automodapi.automodapi', |
212 |
| - 'sphinx_automodapi.smart_resolver', |
213 |
| - 'sphinx_astropy.ext.changelog_links', |
214 |
| - 'sphinx_astropy.ext.generate_config', |
215 |
| - 'sphinx_astropy.ext.missing_static', |
216 |
| - 'sphinx.ext.mathjax'] |
217 |
| - |
218 |
| -try: |
219 |
| - # Do this while in deprecation |
220 |
| - import pytest_doctestplus.sphinx.doctestplus |
221 |
| - extensions += ['pytest_doctestplus.sphinx.doctestplus'] |
222 |
| -except ImportError: |
223 |
| - warnings.warn("sphinx_astropy.ext.doctest has been deprecated " |
224 |
| - "use the doctestplus extensions from pytest-doctestplus: " |
225 |
| - "pytest_doctestplus.sphinx.doctestplus.",DeprecationWarning) |
226 |
| - extensions += ['sphinx_astropy.ext.doctest'] |
| 204 | +extensions = ['sphinx_astropy.ext.intersphinx_toggle', |
| 205 | + 'sphinx.ext.autodoc', |
| 206 | + 'sphinx.ext.intersphinx', |
| 207 | + 'sphinx.ext.todo', |
| 208 | + 'sphinx.ext.coverage', |
| 209 | + 'sphinx.ext.inheritance_diagram', |
| 210 | + 'sphinx.ext.viewcode', |
| 211 | + 'numpydoc', |
| 212 | + 'sphinx_automodapi.automodapi', |
| 213 | + 'sphinx_automodapi.smart_resolver', |
| 214 | + 'sphinx_astropy.ext.changelog_links', |
| 215 | + 'sphinx_astropy.ext.generate_config', |
| 216 | + 'sphinx_astropy.ext.missing_static', |
| 217 | + 'sphinx.ext.mathjax', |
| 218 | + 'pytest_doctestplus.sphinx.doctestplus'] |
227 | 219 |
|
228 | 220 | try:
|
229 | 221 | import matplotlib.sphinxext.plot_directive
|
|
0 commit comments