Compare commits
8 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cca8be3e8b | ||
|
|
c97bb0f3e2 | ||
|
|
383e230ab0 | ||
|
|
f1121b8bac | ||
|
|
379ab359f3 | ||
|
|
fa05224c39 | ||
|
|
cc54017166 | ||
|
|
8f5d120071 |
1
.fmf/version
Normal file
1
.fmf/version
Normal file
@@ -0,0 +1 @@
|
||||
1
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -46,3 +46,5 @@
|
||||
/Sphinx-7.0.1.tar.gz
|
||||
/sphinx-7.1.2.tar.gz
|
||||
/sphinx-7.2.6.tar.gz
|
||||
/sphinx-7.3.7.tar.gz
|
||||
/sphinx-8.1.3.tar.gz
|
||||
|
||||
69
11774.patch
69
11774.patch
@@ -1,69 +0,0 @@
|
||||
From bc8939b34037f81b8610f3b26caec128ee20a2f4 Mon Sep 17 00:00:00 2001
|
||||
From: Karolina Surma <ksurma@redhat.com>
|
||||
Date: Tue, 28 Nov 2023 14:43:58 +0100
|
||||
Subject: [PATCH] Adjust the expected string to match Python 3.11+ changed
|
||||
output
|
||||
|
||||
---
|
||||
tests/test_ext_autodoc_configs.py | 21 +++++++++++++++++----
|
||||
1 file changed, 17 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/tests/test_ext_autodoc_configs.py b/tests/test_ext_autodoc_configs.py
|
||||
index 45bc729b73e..0994c08e899 100644
|
||||
--- a/tests/test_ext_autodoc_configs.py
|
||||
+++ b/tests/test_ext_autodoc_configs.py
|
||||
@@ -11,6 +11,7 @@
|
||||
from .test_ext_autodoc import do_autodoc
|
||||
|
||||
IS_PYPY = platform.python_implementation() == 'PyPy'
|
||||
+IS_PY311_AND_LATER = sys.version_info >= (3, 11)
|
||||
|
||||
|
||||
@contextmanager
|
||||
@@ -1627,7 +1628,10 @@ def test_autodoc_default_options(app):
|
||||
assert ' Iterate squares of each value.' in actual
|
||||
if not IS_PYPY:
|
||||
assert ' .. py:attribute:: CustomIter.__weakref__' in actual
|
||||
- assert ' list of weak references to the object (if defined)' in actual
|
||||
+ if IS_PY311_AND_LATER:
|
||||
+ assert ' list of weak references to the object' in actual
|
||||
+ else:
|
||||
+ assert ' list of weak references to the object (if defined)' in actual
|
||||
|
||||
# :exclude-members: None - has no effect. Unlike :members:,
|
||||
# :special-members:, etc. where None == "include all", here None means
|
||||
@@ -1651,7 +1655,10 @@ def test_autodoc_default_options(app):
|
||||
assert ' Iterate squares of each value.' in actual
|
||||
if not IS_PYPY:
|
||||
assert ' .. py:attribute:: CustomIter.__weakref__' in actual
|
||||
- assert ' list of weak references to the object (if defined)' in actual
|
||||
+ if IS_PY311_AND_LATER:
|
||||
+ assert ' list of weak references to the object' in actual
|
||||
+ else:
|
||||
+ assert ' list of weak references to the object (if defined)' in actual
|
||||
assert ' .. py:method:: CustomIter.snafucate()' in actual
|
||||
assert ' Makes this snafucated.' in actual
|
||||
|
||||
@@ -1698,7 +1705,10 @@ def test_autodoc_default_options_with_values(app):
|
||||
assert ' Iterate squares of each value.' in actual
|
||||
if not IS_PYPY:
|
||||
assert ' .. py:attribute:: CustomIter.__weakref__' not in actual
|
||||
- assert ' list of weak references to the object (if defined)' not in actual
|
||||
+ if IS_PY311_AND_LATER:
|
||||
+ assert ' list of weak references to the object' not in actual
|
||||
+ else:
|
||||
+ assert ' list of weak references to the object (if defined)' not in actual
|
||||
|
||||
# with :exclude-members:
|
||||
app.config.autodoc_default_options = {
|
||||
@@ -1722,6 +1732,9 @@ def test_autodoc_default_options_with_values(app):
|
||||
assert ' Iterate squares of each value.' in actual
|
||||
if not IS_PYPY:
|
||||
assert ' .. py:attribute:: CustomIter.__weakref__' not in actual
|
||||
- assert ' list of weak references to the object (if defined)' not in actual
|
||||
+ if IS_PY311_AND_LATER:
|
||||
+ assert ' list of weak references to the object' not in actual
|
||||
+ else:
|
||||
+ assert ' list of weak references to the object (if defined)' not in actual
|
||||
assert ' .. py:method:: CustomIter.snafucate()' not in actual
|
||||
assert ' Makes this snafucated.' not in actual
|
||||
@@ -1,58 +1,60 @@
|
||||
From 9699465414515f0eba76d05069e755b5bcf34eef Mon Sep 17 00:00:00 2001
|
||||
From: Karolina Surma <ksurma@redhat.com>
|
||||
Date: Mon, 15 Jan 2024 16:19:32 +0100
|
||||
From 14adc6187c936738cb946c24c4a0820223d65066 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= <thrnciar@redhat.com>
|
||||
Date: Wed, 13 Nov 2024 12:25:10 +0100
|
||||
Subject: [PATCH] Make the first party extensions optional, add [extensions]
|
||||
extra
|
||||
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Co-authored-by: Karolina Surma <ksurma@redhat.com>
|
||||
Co-authored-by: Miro Hrončok <miro@hroncok.cz>
|
||||
---
|
||||
pyproject.toml | 33 +++++++++++++++++++++++++++------
|
||||
sphinx/application.py | 6 +++---
|
||||
sphinx/registry.py | 9 ++++++---
|
||||
sphinx/testing/fixtures.py | 6 ++++++
|
||||
tests/test_api_translator.py | 2 ++
|
||||
tests/test_build_html.py | 3 +++
|
||||
6 files changed, 47 insertions(+), 12 deletions(-)
|
||||
pyproject.toml | 33 ++++++++++++++++----
|
||||
sphinx/application.py | 6 ++--
|
||||
sphinx/registry.py | 9 ++++--
|
||||
sphinx/testing/fixtures.py | 7 +++++
|
||||
tests/test_builders/test_build_html_maths.py | 3 ++
|
||||
tests/test_writers/test_api_translator.py | 2 ++
|
||||
6 files changed, 48 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/pyproject.toml b/pyproject.toml
|
||||
index 8f93701..41c28c5 100644
|
||||
index 0812e11..3ead0e0 100644
|
||||
--- a/pyproject.toml
|
||||
+++ b/pyproject.toml
|
||||
@@ -55,12 +55,6 @@ classifiers = [
|
||||
@@ -56,12 +56,6 @@ classifiers = [
|
||||
"Topic :: Utilities",
|
||||
]
|
||||
dependencies = [
|
||||
- "sphinxcontrib-applehelp",
|
||||
- "sphinxcontrib-devhelp",
|
||||
- "sphinxcontrib-jsmath",
|
||||
- "sphinxcontrib-htmlhelp>=2.0.0",
|
||||
- "sphinxcontrib-applehelp>=1.0.7",
|
||||
- "sphinxcontrib-devhelp>=1.0.6",
|
||||
- "sphinxcontrib-htmlhelp>=2.0.6",
|
||||
- "sphinxcontrib-jsmath>=1.0.1",
|
||||
- "sphinxcontrib-qthelp>=1.0.6",
|
||||
- "sphinxcontrib-serializinghtml>=1.1.9",
|
||||
- "sphinxcontrib-qthelp",
|
||||
"Jinja2>=3.0",
|
||||
"Pygments>=2.14",
|
||||
"docutils>=0.18.1,<0.21",
|
||||
@@ -76,8 +70,35 @@ dependencies = [
|
||||
"Jinja2>=3.1",
|
||||
"Pygments>=2.17",
|
||||
"docutils>=0.20,<0.22",
|
||||
@@ -77,8 +71,35 @@ dependencies = [
|
||||
dynamic = ["version"]
|
||||
|
||||
[project.optional-dependencies]
|
||||
+applehelp = [
|
||||
+ "sphinxcontrib-applehelp",
|
||||
+ "sphinxcontrib-applehelp>=1.0.7",
|
||||
+]
|
||||
+devhelp = [
|
||||
+ "sphinxcontrib-devhelp",
|
||||
+ "sphinxcontrib-devhelp>=1.0.6",
|
||||
+]
|
||||
+jsmath = [
|
||||
+ "sphinxcontrib-jsmath",
|
||||
+ "sphinxcontrib-jsmath>=1.0.1",
|
||||
+]
|
||||
+htmlhelp = [
|
||||
+ "sphinxcontrib-htmlhelp>=2.0.0",
|
||||
+ "sphinxcontrib-htmlhelp>=2.0.6",
|
||||
+]
|
||||
+serializinghtml = [
|
||||
+ "sphinxcontrib-serializinghtml>=1.1.9",
|
||||
+]
|
||||
+qthelp = [
|
||||
+ "sphinxcontrib-qthelp",
|
||||
+ "sphinxcontrib-qthelp>=1.0.6",
|
||||
+]
|
||||
+extensions = [
|
||||
+ "sphinx[applehelp]",
|
||||
@@ -67,12 +69,12 @@ index 8f93701..41c28c5 100644
|
||||
+ "sphinx[extensions]",
|
||||
]
|
||||
lint = [
|
||||
"flake8>=3.5.0",
|
||||
"flake8>=6.0",
|
||||
diff --git a/sphinx/application.py b/sphinx/application.py
|
||||
index d5fbaa9..b030dab 100644
|
||||
index 872dd7a..21f9be0 100644
|
||||
--- a/sphinx/application.py
|
||||
+++ b/sphinx/application.py
|
||||
@@ -226,7 +226,7 @@ class Sphinx:
|
||||
@@ -249,7 +249,7 @@ class Sphinx:
|
||||
# load all built-in extension modules, first-party extension modules,
|
||||
# and first-party themes
|
||||
for extension in builtin_extensions:
|
||||
@@ -81,7 +83,7 @@ index d5fbaa9..b030dab 100644
|
||||
|
||||
# load all user-given extension modules
|
||||
for extension in self.config.extensions:
|
||||
@@ -395,7 +395,7 @@ class Sphinx:
|
||||
@@ -426,7 +426,7 @@ class Sphinx:
|
||||
|
||||
# ---- general extensibility interface -------------------------------------
|
||||
|
||||
@@ -90,7 +92,7 @@ index d5fbaa9..b030dab 100644
|
||||
"""Import and setup a Sphinx extension module.
|
||||
|
||||
Load the extension given by the module *name*. Use this if your
|
||||
@@ -403,7 +403,7 @@ class Sphinx:
|
||||
@@ -434,7 +434,7 @@ class Sphinx:
|
||||
called twice.
|
||||
"""
|
||||
logger.debug('[app] setting up extension: %r', extname)
|
||||
@@ -100,10 +102,10 @@ index d5fbaa9..b030dab 100644
|
||||
@staticmethod
|
||||
def require_sphinx(version: tuple[int, int] | str) -> None:
|
||||
diff --git a/sphinx/registry.py b/sphinx/registry.py
|
||||
index 501661d..96d4554 100644
|
||||
index da21aef..c3f87e0 100644
|
||||
--- a/sphinx/registry.py
|
||||
+++ b/sphinx/registry.py
|
||||
@@ -430,7 +430,7 @@ class SphinxComponentRegistry:
|
||||
@@ -436,7 +436,7 @@ class SphinxComponentRegistry:
|
||||
def add_html_theme(self, name: str, theme_path: str) -> None:
|
||||
self.html_themes[name] = theme_path
|
||||
|
||||
@@ -112,7 +114,7 @@ index 501661d..96d4554 100644
|
||||
"""Load a Sphinx extension."""
|
||||
if extname in app.extensions: # already loaded
|
||||
return
|
||||
@@ -446,9 +446,12 @@ class SphinxComponentRegistry:
|
||||
@@ -452,9 +452,12 @@ class SphinxComponentRegistry:
|
||||
try:
|
||||
mod = import_module(extname)
|
||||
except ImportError as err:
|
||||
@@ -125,24 +127,25 @@ index 501661d..96d4554 100644
|
||||
- err) from err
|
||||
+ raise ExtensionError(msg % extname, err) from err
|
||||
|
||||
setup = getattr(mod, 'setup', None)
|
||||
setup: _ExtensionSetupFunc | None = getattr(mod, 'setup', None)
|
||||
if setup is None:
|
||||
diff --git a/sphinx/testing/fixtures.py b/sphinx/testing/fixtures.py
|
||||
index 0cc4882..f57f709 100644
|
||||
index 6f1c29c..425e026 100644
|
||||
--- a/sphinx/testing/fixtures.py
|
||||
+++ b/sphinx/testing/fixtures.py
|
||||
@@ -22,6 +22,7 @@ DEFAULT_ENABLED_MARKERS = [
|
||||
'sphinx(builder, testroot=None, freshenv=False, confoverrides=None, tags=None,'
|
||||
' docutilsconf=None, parallel=0): arguments to initialize the sphinx test application.'
|
||||
@@ -31,6 +31,7 @@ DEFAULT_ENABLED_MARKERS = [
|
||||
'builddir=None, docutils_conf=None'
|
||||
'): arguments to initialize the sphinx test application.'
|
||||
),
|
||||
+ 'sphinxcontrib(...): required sphinxcontrib.* extensions',
|
||||
'test_params(shared_result=...): test parameters.',
|
||||
]
|
||||
|
||||
@@ -67,6 +68,11 @@ def app_params(request: Any, test_params: dict, shared_result: SharedResult,
|
||||
@@ -80,6 +81,12 @@ def app_params(
|
||||
Parameters that are specified by 'pytest.mark.sphinx' for
|
||||
sphinx.application.Sphinx initialization
|
||||
"""
|
||||
|
||||
+
|
||||
+ # ##### process pytest.mark.sphinxcontrib
|
||||
+ for info in reversed(list(request.node.iter_markers("sphinxcontrib"))):
|
||||
+ for arg in info.args:
|
||||
@@ -150,55 +153,55 @@ index 0cc4882..f57f709 100644
|
||||
+
|
||||
# ##### process pytest.mark.sphinx
|
||||
|
||||
pargs = {}
|
||||
diff --git a/tests/test_api_translator.py b/tests/test_api_translator.py
|
||||
index 9f2bd44..81575b7 100644
|
||||
--- a/tests/test_api_translator.py
|
||||
+++ b/tests/test_api_translator.py
|
||||
@@ -36,6 +36,7 @@ def test_singlehtml_set_translator_for_singlehtml(app, status, warning):
|
||||
pargs: dict[int, Any] = {}
|
||||
diff --git a/tests/test_builders/test_build_html_maths.py b/tests/test_builders/test_build_html_maths.py
|
||||
index 0f77691..bc87e98 100644
|
||||
--- a/tests/test_builders/test_build_html_maths.py
|
||||
+++ b/tests/test_builders/test_build_html_maths.py
|
||||
@@ -26,6 +26,7 @@ def test_html_math_renderer_is_imgmath(app):
|
||||
assert app.builder.math_renderer_name == 'imgmath'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('serializinghtml', 'jsmath')
|
||||
@pytest.mark.sphinx(
|
||||
'html',
|
||||
testroot='basic',
|
||||
@@ -50,6 +51,7 @@ def test_html_math_renderer_is_duplicated2(app):
|
||||
assert app.builder.math_renderer_name == 'imgmath' # The another one is chosen
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('jsmath')
|
||||
@pytest.mark.sphinx(
|
||||
'html',
|
||||
testroot='basic',
|
||||
@@ -62,6 +64,7 @@ def test_html_math_renderer_is_chosen(app):
|
||||
assert app.builder.math_renderer_name == 'imgmath'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('jsmath')
|
||||
@pytest.mark.sphinx(
|
||||
'html',
|
||||
testroot='basic',
|
||||
diff --git a/tests/test_writers/test_api_translator.py b/tests/test_writers/test_api_translator.py
|
||||
index bdbea0d..01d4d35 100644
|
||||
--- a/tests/test_writers/test_api_translator.py
|
||||
+++ b/tests/test_writers/test_api_translator.py
|
||||
@@ -36,6 +36,7 @@ def test_singlehtml_set_translator_for_singlehtml(app):
|
||||
assert translator_class.__name__ == 'ConfSingleHTMLTranslator'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('serializinghtml')
|
||||
@pytest.mark.sphinx('pickle', testroot='api-set-translator')
|
||||
def test_pickle_set_translator_for_pickle(app, status, warning):
|
||||
def test_pickle_set_translator_for_pickle(app):
|
||||
translator_class = app.builder.get_translator_class()
|
||||
@@ -43,6 +44,7 @@ def test_pickle_set_translator_for_pickle(app, status, warning):
|
||||
@@ -43,6 +44,7 @@ def test_pickle_set_translator_for_pickle(app):
|
||||
assert translator_class.__name__ == 'ConfPickleTranslator'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('serializinghtml')
|
||||
@pytest.mark.sphinx('json', testroot='api-set-translator')
|
||||
def test_json_set_translator_for_json(app, status, warning):
|
||||
def test_json_set_translator_for_json(app):
|
||||
translator_class = app.builder.get_translator_class()
|
||||
diff --git a/tests/test_build_html.py b/tests/test_build_html.py
|
||||
index 07f101d..c512a33 100644
|
||||
--- a/tests/test_build_html.py
|
||||
+++ b/tests/test_build_html.py
|
||||
@@ -1544,6 +1544,7 @@ def test_html_math_renderer_is_imgmath(app, status, warning):
|
||||
assert app.builder.math_renderer_name == 'imgmath'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('serializinghtml', 'jsmath')
|
||||
@pytest.mark.sphinx('html', testroot='basic',
|
||||
confoverrides={'extensions': ['sphinxcontrib.jsmath',
|
||||
'sphinx.ext.imgmath']})
|
||||
@@ -1564,6 +1565,7 @@ def test_html_math_renderer_is_duplicated2(app, status, warning):
|
||||
assert app.builder.math_renderer_name == 'imgmath' # The another one is chosen
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('jsmath')
|
||||
@pytest.mark.sphinx('html', testroot='basic',
|
||||
confoverrides={'extensions': ['sphinxcontrib.jsmath',
|
||||
'sphinx.ext.imgmath'],
|
||||
@@ -1572,6 +1574,7 @@ def test_html_math_renderer_is_chosen(app, status, warning):
|
||||
assert app.builder.math_renderer_name == 'imgmath'
|
||||
|
||||
|
||||
+@pytest.mark.sphinxcontrib('jsmath')
|
||||
@pytest.mark.sphinx('html', testroot='basic',
|
||||
confoverrides={'extensions': ['sphinxcontrib.jsmath',
|
||||
'sphinx.ext.mathjax'],
|
||||
--
|
||||
2.43.0
|
||||
2.47.0
|
||||
|
||||
|
||||
@@ -14,14 +14,12 @@
|
||||
|
||||
# Build without BuildRequires ImageMagick, to skip imgconverter tests
|
||||
%bcond imagemagick_tests %{undefined rhel}
|
||||
# Same for filelock -- we don't want it in RHEL just to run a handful of tests here
|
||||
%bcond filelock_tests %{undefined rhel}
|
||||
|
||||
# During texlive updates, sometimes the latex environment is unstable
|
||||
%bcond latex_tests 1
|
||||
|
||||
Name: python-sphinx
|
||||
%global general_version 7.2.6
|
||||
%global general_version 8.1.3
|
||||
#global prerel ...
|
||||
%global upstream_version %{general_version}%{?prerel}
|
||||
Version: %{general_version}%{?prerel:~%{prerel}}
|
||||
@@ -38,7 +36,7 @@ Source: %{pypi_source sphinx %{upstream_version}}
|
||||
|
||||
# Allow extra themes to exist. We pull in python3-sphinx-theme-alabaster
|
||||
# which causes that test to fail.
|
||||
Patch: sphinx-test_theming.diff
|
||||
Patch: sphinx-test_theming.patch
|
||||
|
||||
# Make the first party extensions optional
|
||||
# This removes the runtime dependencies on:
|
||||
@@ -56,10 +54,6 @@ Patch: sphinx-test_theming.diff
|
||||
# https://github.com/sphinx-doc/sphinx/pull/11747
|
||||
Patch: Make-the-first-party-extensions-optional.patch
|
||||
|
||||
# Fix the expected test docstring to match output in Python 3.11.7, 3.12.1 and later
|
||||
# Proposed upstream.
|
||||
Patch: https://github.com/sphinx-doc/sphinx/pull/11774.patch
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: make
|
||||
@@ -265,26 +259,9 @@ This package contains documentation in the HTML format.
|
||||
%autosetup -n sphinx-%{upstream_version} -p1
|
||||
|
||||
%if %{without imagemagick_tests}
|
||||
rm tests/test_ext_imgconverter.py
|
||||
rm tests/test_extensions/test_ext_imgconverter.py
|
||||
%endif
|
||||
|
||||
%if %{without filelock_tests}
|
||||
sed -i '/filelock/d' pyproject.toml
|
||||
rm tests/test_build_linkcheck.py tests/test_ext_intersphinx.py
|
||||
%endif
|
||||
|
||||
%if %{defined rhel}
|
||||
# unwanted dependency in RHEL, https://bugzilla.redhat.com/show_bug.cgi?id=1945182
|
||||
sed -i '/html5lib/d' pyproject.toml
|
||||
%endif
|
||||
|
||||
# Sphinx' tests import from each other, this feature is not supported by
|
||||
# the 'importlib' import mode in pytest. Upstream mitigates this by invoking
|
||||
# `python -m pytest` rather than `pytest` directly, but in the context of the
|
||||
# RPM build we explicitly want to test the installed library rather than the
|
||||
# one from PWD.
|
||||
# https://github.com/sphinx-doc/sphinx/issues/11740
|
||||
sed -i '/"--import-mode=importlib",/d' pyproject.toml
|
||||
|
||||
%generate_buildrequires
|
||||
%pyproject_buildrequires -r %{?with_tests:-x test}
|
||||
@@ -364,25 +341,20 @@ mkdir %{buildroot}%{python3_sitelib}/sphinxcontrib
|
||||
# Currently, all linkcheck tests and test_latex_images need internet
|
||||
# test_build_latex_doc needs internet to download pictures,
|
||||
# but fails also with it enabled, we decided to skip it entirely
|
||||
# In RHEL builds, skip tests which use html5lib (excluded above)
|
||||
%pytest \
|
||||
%if %{defined rhel}
|
||||
--ignore tests/test_build_html.py \
|
||||
--ignore tests/test_build_latex.py \
|
||||
--ignore tests/test_build_texinfo.py \
|
||||
--ignore tests/test_domain_std.py \
|
||||
--ignore tests/test_smartquotes.py \
|
||||
%endif
|
||||
# test_autodoc_type_aliases fails with Python 3.12.4, 3.13.0b3
|
||||
# skip temporarily until resolved:
|
||||
# https://github.com/sphinx-doc/sphinx/issues/12430
|
||||
k="not test_autodoc_type_aliases"
|
||||
%if %{without internet}
|
||||
-k "not linkcheck and not test_latex_images and not test_build_latex_doc" \
|
||||
%endif
|
||||
;
|
||||
k="${k} and not linkcheck and not test_latex_images and not test_build_latex_doc"
|
||||
%endif
|
||||
|
||||
%pytest -k "${k}"
|
||||
%endif
|
||||
|
||||
%files -n python%{python3_pkgversion}-sphinx -f sphinx.lang
|
||||
%license LICENSE
|
||||
%doc AUTHORS CHANGES EXAMPLES README.rst
|
||||
%license LICENSE.rst
|
||||
%doc README.rst
|
||||
%{_bindir}/sphinx-*
|
||||
%{python3_sitelib}/sphinx/
|
||||
%dir %{python3_sitelib}/sphinxcontrib/
|
||||
@@ -398,7 +370,7 @@ mkdir %{buildroot}%{python3_sitelib}/sphinxcontrib
|
||||
|
||||
|
||||
%files doc
|
||||
%license LICENSE
|
||||
%license LICENSE.rst
|
||||
%doc html
|
||||
|
||||
|
||||
|
||||
2
sources
2
sources
@@ -1 +1 @@
|
||||
SHA512 (sphinx-7.2.6.tar.gz) = 9a42e38c3c54429cc008b58892297ade4ccdd67561ee671e42a1fae976955895bb5383d58cb66a4f9f7edd1cc50dc2d1f083efeef036eac9fffc205979d3ccbc
|
||||
SHA512 (sphinx-8.1.3.tar.gz) = 938fc78941fd7b2bf3382730f2f9d322d406f87c80c0e4bf4c051a85a352c2c6241fe5b8d21574de7e4c1528090955eb84b6d23813b377b2be198a2cfa70221f
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
diff -ru Sphinx-1.7.6/tests/test_theming.py Sphinx-1.7.6_patched/tests/test_theming.py
|
||||
--- Sphinx-1.7.6/tests/test_theming.py 2018-07-16 11:24:40.000000000 +0200
|
||||
+++ Sphinx-1.7.6_patched/tests/test_theming.py 2018-07-20 15:17:35.049263077 +0200
|
||||
@@ -25,7 +25,7 @@
|
||||
themes.append('alabaster')
|
||||
|
||||
# test Theme class API
|
||||
- assert set(app.registry.html_themes.keys()) == set(themes)
|
||||
+ assert set(app.registry.html_themes.keys()) >= set(themes)
|
||||
assert app.registry.html_themes['test-theme'] == str(app.srcdir / 'test_theme' / 'test-theme')
|
||||
assert app.registry.html_themes['ziptheme'] == str(app.srcdir / 'ziptheme.zip')
|
||||
assert app.registry.html_themes['staticfiles'] == str(app.srcdir / 'test_theme' / 'staticfiles')
|
||||
25
sphinx-test_theming.patch
Normal file
25
sphinx-test_theming.patch
Normal file
@@ -0,0 +1,25 @@
|
||||
From 57433d8036ab1e88ad7d6c4c1a45e438f722e276 Mon Sep 17 00:00:00 2001
|
||||
From: Karolina Surma <ksurma@redhat.com>
|
||||
Date: Thu, 25 Apr 2024 16:07:56 +0200
|
||||
Subject: [PATCH] Patch test_theming to accomodate for Fedora-added theme
|
||||
|
||||
---
|
||||
tests/test_theming/test_theming.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/test_theming/test_theming.py b/tests/test_theming/test_theming.py
|
||||
index 867f8a0..281bb45 100644
|
||||
--- a/tests/test_theming/test_theming.py
|
||||
+++ b/tests/test_theming/test_theming.py
|
||||
@@ -50,7 +50,7 @@ def test_theme_api(app, status, warning):
|
||||
]
|
||||
|
||||
# test Theme class API
|
||||
- assert set(app.registry.html_themes.keys()) == set(themes)
|
||||
+ assert set(app.registry.html_themes.keys()) >= set(themes)
|
||||
assert app.registry.html_themes['test-theme'] == str(
|
||||
app.srcdir / 'test_theme' / 'test-theme'
|
||||
)
|
||||
--
|
||||
2.44.0
|
||||
|
||||
11
tests/include-sphinxcontrib-jquery/main.fmf
Normal file
11
tests/include-sphinxcontrib-jquery/main.fmf
Normal file
@@ -0,0 +1,11 @@
|
||||
summary: run the basic documentation build
|
||||
test: |
|
||||
sphinx-build -M html source/ build/ &&
|
||||
grep '<script src="_static/jquery.js' build/html/index.html &&
|
||||
grep '<script src="_static/_sphinx_javascript_frameworks_compat.js' build/html/index.html &&
|
||||
test -f build/html/_static/jquery.js &&
|
||||
test -f build/html/_static/_sphinx_javascript_frameworks_compat.js &&
|
||||
rm -rf build/
|
||||
require:
|
||||
- python3-sphinx
|
||||
- python3-sphinxcontrib-jquery
|
||||
7
tests/include-sphinxcontrib-jquery/source/conf.py
Normal file
7
tests/include-sphinxcontrib-jquery/source/conf.py
Normal file
@@ -0,0 +1,7 @@
|
||||
project = 'Test'
|
||||
copyright = '2024, Test'
|
||||
author = 'Test'
|
||||
release = '0.3.0'
|
||||
extensions = [
|
||||
"sphinxcontrib.jquery",
|
||||
]
|
||||
15
tests/include-sphinxcontrib-jquery/source/index.rst
Normal file
15
tests/include-sphinxcontrib-jquery/source/index.rst
Normal file
@@ -0,0 +1,15 @@
|
||||
Test docfile
|
||||
============
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
:caption: Contents:
|
||||
|
||||
|
||||
|
||||
Indices and tables
|
||||
==================
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
10
tests/smoke-alabaster/main.fmf
Normal file
10
tests/smoke-alabaster/main.fmf
Normal file
@@ -0,0 +1,10 @@
|
||||
summary: run the basic documentation build
|
||||
test: |
|
||||
sphinx-build -M html source/ build/ &&
|
||||
grep '<section id="test-docfile">' build/html/index.html &&
|
||||
grep '<h1>Test docfile' build/html/index.html &&
|
||||
grep '_static/alabaster.css' build/html/index.html &&
|
||||
rm -rf build/
|
||||
require:
|
||||
- python3-sphinx
|
||||
- python3-sphinx-theme-alabaster
|
||||
5
tests/smoke-alabaster/source/conf.py
Normal file
5
tests/smoke-alabaster/source/conf.py
Normal file
@@ -0,0 +1,5 @@
|
||||
project = 'Test'
|
||||
copyright = '2024, Test'
|
||||
author = 'Test'
|
||||
release = '0.3.0'
|
||||
html_theme = 'alabaster'
|
||||
15
tests/smoke-alabaster/source/index.rst
Normal file
15
tests/smoke-alabaster/source/index.rst
Normal file
@@ -0,0 +1,15 @@
|
||||
Test docfile
|
||||
============
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
:caption: Contents:
|
||||
|
||||
|
||||
|
||||
Indices and tables
|
||||
==================
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
11
tests/smoke-rtd-theme/main.fmf
Normal file
11
tests/smoke-rtd-theme/main.fmf
Normal file
@@ -0,0 +1,11 @@
|
||||
summary: run the basic documentation build with sphinx-rtd-theme
|
||||
test: |
|
||||
sphinx-build -M html source/ build/ &&
|
||||
grep '<section id="test-docfile">' build/html/index.html &&
|
||||
grep '<h1>Test docfile' build/html/index.html &&
|
||||
grep 'SphinxRtdTheme' build/html/_static/js/theme.js &&
|
||||
grep '<script src="_static/js/theme.js' build/html/index.html &&
|
||||
rm -rf build/
|
||||
require:
|
||||
- python3-sphinx
|
||||
- python3-sphinx_rtd_theme
|
||||
8
tests/smoke-rtd-theme/source/conf.py
Normal file
8
tests/smoke-rtd-theme/source/conf.py
Normal file
@@ -0,0 +1,8 @@
|
||||
project = 'Test'
|
||||
copyright = '2024, Test'
|
||||
author = 'Test'
|
||||
release = '0.3.0'
|
||||
html_theme = 'sphinx_rtd_theme'
|
||||
extensions = [
|
||||
'sphinx_rtd_theme',
|
||||
]
|
||||
15
tests/smoke-rtd-theme/source/index.rst
Normal file
15
tests/smoke-rtd-theme/source/index.rst
Normal file
@@ -0,0 +1,15 @@
|
||||
Test docfile
|
||||
============
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
:caption: Contents:
|
||||
|
||||
|
||||
|
||||
Indices and tables
|
||||
==================
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
Reference in New Issue
Block a user