diff --git a/python-jinja2.spec b/python-jinja2.spec index 053e95d..4692a09 100644 --- a/python-jinja2.spec +++ b/python-jinja2.spec @@ -20,6 +20,8 @@ Patch: python3.13.patch %else %bcond_without docs %endif +# The dependency on trio is undesired on RHEL +%bcond asyncio_tests %{undefined rhel} BuildArch: noarch @@ -40,7 +42,9 @@ environments.} Summary: %{summary} BuildRequires: python3-devel BuildRequires: python3-pytest +%if %{with asyncio_tests} BuildRequires: python3-trio +%endif %if %{with docs} BuildRequires: %{_bindir}/sphinx-build-3 BuildRequires: make @@ -77,7 +81,7 @@ rm -rvf docs/_build/html/.buildinfo %check -%pytest tests +%pytest tests %{!?with_asyncio_tests:--ignore tests/test_async.py --ignore tests/test_async_filters.py} %files -n python3-jinja2 -f %{pyproject_files}