Run unit tests in %check
This commit is contained in:
parent
11f139716a
commit
8b34027242
@ -1,6 +1,7 @@
|
|||||||
# Created by pyp2rpm-3.3.6
|
# Created by pyp2rpm-3.3.6
|
||||||
%global pypi_name resolvelib
|
%global pypi_name resolvelib
|
||||||
%global forgeurl https://github.com/sarugaku/resolvelib
|
%global forgeurl https://github.com/sarugaku/resolvelib
|
||||||
|
%bcond tests 1
|
||||||
|
|
||||||
Name: python-%{pypi_name}
|
Name: python-%{pypi_name}
|
||||||
Version: 1.0.1
|
Version: 1.0.1
|
||||||
@ -35,10 +36,13 @@ Summary: %{summary}
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup %{forgesetupargs}
|
%autosetup %{forgesetupargs}
|
||||||
|
# Use already packaged json5 instead of commentjson
|
||||||
|
sed -i 's|commentjson|json5|' \
|
||||||
|
setup.cfg tests/functional/cocoapods/test_resolvers_cocoapods.py
|
||||||
|
|
||||||
|
|
||||||
%generate_buildrequires
|
%generate_buildrequires
|
||||||
%pyproject_buildrequires
|
%pyproject_buildrequires %{?with_tests:-x test}
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@ -49,6 +53,9 @@ Summary: %{summary}
|
|||||||
%pyproject_install
|
%pyproject_install
|
||||||
%pyproject_save_files %{pypi_name}
|
%pyproject_save_files %{pypi_name}
|
||||||
|
|
||||||
|
%check
|
||||||
|
%pytest -v
|
||||||
|
|
||||||
|
|
||||||
%files -n python3-%{pypi_name} -f %{pyproject_files}
|
%files -n python3-%{pypi_name} -f %{pyproject_files}
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
|
Loading…
Reference in New Issue
Block a user