sphinx/tests/test_extensions
Chris Sewell bc1a5c5c88
[autogen] Add --remove-old option (#12456)
A common "gotcha" of re-running `sphinx-autogen`, is that if there are changes it will not remove old files, leading to build errors for files not in a `toctree`

This commit introduces a `--remove-old` option to remove these files.

Note, a key detail here is that we don't want to simply clear the directory before running `sphinx-autogen`,
since this would lead to all files having a new `mtime`,
and then `sphinx-build` would rebuild all of them even if they have not changed.
So we must first collect the list of all correct files, then remove any not in the list.
2024-06-21 19:29:46 +02:00
..
__init__.py Organise tests into directories 2024-01-17 03:56:35 +00:00
autodoc_util.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
ext_napoleon_pep526_data_google.py Organise tests into directories 2024-01-17 03:56:35 +00:00
ext_napoleon_pep526_data_numpy.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_apidoc.py [apidoc] Add --remove-old option (#12448) 2024-06-20 13:12:37 +02:00
test_ext_autodoc_autoattribute.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_autoclass.py Don't render types with `Optional[...]` 2024-04-15 01:35:47 +01:00
test_ext_autodoc_autodata.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_autofunction.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_automodule.py Improve type hints for `sphinx.ext.autodoc.mock` (#12280) 2024-04-22 23:23:57 +01:00
test_ext_autodoc_autoproperty.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_configs.py 🧪 Fix python 3.13 tests (#12373) 2024-05-15 06:28:40 +02:00
test_ext_autodoc_events.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_mock.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_autodoc_preserve_defaults.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc_private_members.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_autodoc.py 🧪 Fix python 3.13 tests (#12373) 2024-05-15 06:28:40 +02:00
test_ext_autosectionlabel.py Use long `re` flags 2024-01-19 02:28:06 +00:00
test_ext_autosummary.py [autogen] Add --remove-old option (#12456) 2024-06-21 19:29:46 +02:00
test_ext_coverage.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_doctest.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_duration.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_extlinks.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_githubpages.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_graphviz.py Use long `re` flags 2024-01-19 02:28:06 +00:00
test_ext_ifconfig.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_imgconverter.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_imgmockconverter.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_inheritance_diagram.py Use long `re` flags 2024-01-19 02:28:06 +00:00
test_ext_intersphinx.py Intersphinx: log warnings for ambiguous target resolutions. (#12329) 2024-06-17 12:42:22 +02:00
test_ext_math.py Use long `re` flags 2024-01-19 02:28:06 +00:00
test_ext_napoleon_docstring.py [tests] move utilities and static data into dedicated modules and remove `html5lib` (#12173) 2024-03-25 11:03:44 +01:00
test_ext_napoleon.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_todo.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_ext_viewcode.py Organise tests into directories 2024-01-17 03:56:35 +00:00
test_extension.py Organise tests into directories 2024-01-17 03:56:35 +00:00