%global pkgname pytest-services %global srcname pytest_services %global _description \ The plugin provides a set of fixtures and utility functions to start service processes for your tests with pytest # pylibmc package is missing #%%bcond_without tests %bcond_with tests Name: python-%{pkgname} Version: 2.1.0 Release: 1%{?dist} Summary: Services plugin for pytest testing framework License: MIT URL: https://github.com/pytest-dev/pytest-services BuildArch: noarch # the pypi version comes without tests #Source0: %%{pypi_source} Source0: https://github.com/pytest-dev/pytest-services/archive/%{version}.tar.gz BuildRequires: python%{python3_pkgversion}-devel >= 3.4 BuildRequires: python%{python3_pkgversion}-setuptools # Test suite %if %{with tests} BuildRequires: python%{python3_pkgversion}-pytest BuildRequires: python%{python3_pkgversion}-requests BuildRequires: python%{python3_pkgversion}-psutil BuildRequires: python%{python3_pkgversion}-zc-lockfile BuildRequires: python%{python3_pkgversion}-pylibmc %endif %description %{_description} %package -n python%{python3_pkgversion}-%{pkgname} Summary: %{summary} %{?python_provide:%python_provide python%{python3_pkgversion}-%{pkgname}} Requires: python%{python3_pkgversion}-requests Requires: python%{python3_pkgversion}-psutil Requires: python%{python3_pkgversion}-zc-lockfile %description -n python%{python3_pkgversion}-%{pkgname} %{_description} %prep %autosetup -p1 -n %{pkgname}-%{version} %build %py3_build %install %py3_install %check %if %{with tests} py.test-3 tests %endif %files -n python%{python3_pkgversion}-%{pkgname} %license LICENSE.txt %doc README.rst %{python3_sitelib}/%{srcname} %{python3_sitelib}/%{srcname}-%{version}*-py?.?.egg-info %changelog * Fri Jun 19 2020 Marc Dequènes (Duck) - 2.1.0-1 - Initial package.