Deprecate legacy `intersphinx_mapping` format (#11247)

This format was made obsolete in Sphinx 1.0, but never formally deprecated.
This commit is contained in:
Adam Turner
2023-03-17 16:41:22 +00:00
committed by GitHub
parent 7a4ce71f6b
commit 2902c6c55b
3 changed files with 35 additions and 12 deletions

View File

@@ -390,7 +390,10 @@ def test_load_mappings_warnings(tempdir, app, status, warning):
# load the inventory and check if it's done correctly
normalize_intersphinx_mapping(app, app.config)
load_mappings(app)
assert warning.getvalue().count('\n') == 1
warnings = warning.getvalue().splitlines()
assert len(warnings) == 2
assert "The pre-Sphinx 1.0 'intersphinx_mapping' format is " in warnings[0]
assert 'intersphinx identifier 12345 is not string. Ignored' in warnings[1]
def test_load_mappings_fallback(tempdir, app, status, warning):