diff --git a/python-zope-exceptions.spec b/python-zope-exceptions.spec index 27d6562..6e3494a 100644 --- a/python-zope-exceptions.spec +++ b/python-zope-exceptions.spec @@ -18,6 +18,10 @@ general purpose that they don't belong in Zope application-specific packages. Summary: Zope Exceptions BuildRequires: python3-devel +# There is a test dependency loop, so we need a way to build this without tests +# zope.exceptions -> zope.testrunner-> zope.exceptions +%bcond tests 1 + %description -n python3-zope-exceptions This package contains exception interfaces and implementations which are so general purpose that they don't belong in Zope application-specific packages. @@ -26,7 +30,7 @@ general purpose that they don't belong in Zope application-specific packages. %autosetup -n %{modname}-%{version} %generate_buildrequires -%pyproject_buildrequires -t +%pyproject_buildrequires %{?with_tests:-t} %build %pyproject_wheel @@ -36,7 +40,10 @@ general purpose that they don't belong in Zope application-specific packages. %pyproject_save_files zope %check +%pyproject_check_import +%if %{with tests} %tox +%endif %files -n python3-zope-exceptions -f %{pyproject_files} %doc CHANGES.rst README.rst