55 lines
1.5 KiB
RPMSpec
55 lines
1.5 KiB
RPMSpec
%global pypi_name pytest-forked
|
|
%global desc The pytest-forked plugin extends py.test by adding an option to run tests in\
|
|
isolated forked subprocesses. This is useful if you have tests involving C or\
|
|
C++ libraries that might crash the process. To use the plugin, simply use the\
|
|
--forked argument when invoking py.test.
|
|
|
|
Name: python-%{pypi_name}
|
|
Version: 1.0.2
|
|
Release: 1
|
|
Summary: py.test plugin for running tests in isolated forked subprocesses
|
|
|
|
License: MIT
|
|
URL: https://github.com/pytest-dev/pytest-forked
|
|
Source0: https://files.pythonhosted.org/packages/source/p/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
|
|
BuildArch: noarch
|
|
Patch1: add-compatibility-with-Pytest-5.4.0.patch
|
|
|
|
BuildRequires: python3-devel
|
|
BuildRequires: python3-py python3-pytest python3-setuptools_scm
|
|
|
|
%description
|
|
%{desc}
|
|
|
|
%package -n python3-%{pypi_name}
|
|
Summary: %{summary}
|
|
%{?python_provide:%python_provide python3-%{pypi_name}}
|
|
|
|
Requires: python3-py python3-pytest
|
|
%description -n python3-%{pypi_name}
|
|
%{desc}
|
|
|
|
%prep
|
|
%autosetup -p1 -n %{pypi_name}-%{version}
|
|
rm -f testing/conftest.pyc
|
|
rm -rf testing/__pycache__
|
|
|
|
%build
|
|
%py3_build
|
|
|
|
%install
|
|
%py3_install
|
|
|
|
%check
|
|
PYTHONPATH=%{buildroot}%{python3_sitelib} py.test-%{python3_version} testing
|
|
|
|
%files -n python3-%{pypi_name}
|
|
%doc example/boxed.txt README.rst
|
|
%license LICENSE
|
|
%{python3_sitelib}/pytest_forked*
|
|
|
|
%changelog
|
|
* Tue Jul 06 2021 wangdi <wangdi@kylinos.cn> - 1.0.2-1
|
|
- Init package for version 1.0.2
|
|
|