Avoid tox dependency

RHEL does not include tox, but even in Fedora it add much value relative to
its dependencies; calling %pytest directly is simpler.
This commit is contained in:
Yaakov Selkowitz
2025-08-02 07:12:56 -04:00
committed by Benjamin A. Beasley
parent b19b912e43
commit c1a65cba5d
+11 -2
View File
@@ -10,7 +10,16 @@ Source: %{pypi_source pytest_subtests}
BuildSystem: pyproject
BuildOption(install): -l pytest_subtests
BuildOption(generate_buildrequires): -t
# Dont depend on pytest-xdist on RHEL/ELN, since its unwanted there. Keep the
# dependency in Fedora because it enables several integration tests.
#
# (For similar reasons, we dont pass -t to %%pyproject_buildrequires and we
# run tests via %%pytest directly instead of via %%tox: tox is unwanted in
# RHEL/ELN, and the benefit of using it in this package is small.)
%if %{undefined rhel}
BuildRequires: python3dist(pytest-xdist)
%endif
BuildArch: noarch
@@ -26,7 +35,7 @@ Summary: %{summary}
%check -a
%tox -- -- -rs -v tests
%pytest -rs -v tests
%files -n python3-pytest-subtests -f %{pyproject_files}