Make the build dependency on trio optional
(cherry picked from commit 0aec2152b2acae1d1a1ab75ab1e951de15fdc2a1)
This commit is contained in:
parent
480ab3098c
commit
18ea04d057
@ -15,6 +15,8 @@ Source0: %{pypi_source %srcname}
|
|||||||
%else
|
%else
|
||||||
%bcond_without docs
|
%bcond_without docs
|
||||||
%endif
|
%endif
|
||||||
|
# The dependency on trio is undesired on RHEL
|
||||||
|
%bcond asyncio_tests %{undefined rhel}
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
@ -35,6 +37,9 @@ environments.}
|
|||||||
Summary: %{summary}
|
Summary: %{summary}
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: python3-pytest
|
BuildRequires: python3-pytest
|
||||||
|
%if %{with asyncio_tests}
|
||||||
|
BuildRequires: python3-trio
|
||||||
|
%endif
|
||||||
%if %{with docs}
|
%if %{with docs}
|
||||||
BuildRequires: %{_bindir}/sphinx-build-3
|
BuildRequires: %{_bindir}/sphinx-build-3
|
||||||
BuildRequires: make
|
BuildRequires: make
|
||||||
@ -73,7 +78,7 @@ rm -rvf docs/_build/html/.buildinfo
|
|||||||
|
|
||||||
|
|
||||||
%check
|
%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}
|
%files -n python3-jinja2 -f %{pyproject_files}
|
||||||
|
Loading…
Reference in New Issue
Block a user