Blame tests/python-pytest.spec

d81f3d
%global pypi_name pytest
d81f3d
Name:           python-%{pypi_name}
fdf511
Version:        4.4.2
d81f3d
Release:        0%{?dist}
d81f3d
Summary:        Simple powerful testing with Python
d81f3d
License:        MIT
d81f3d
URL:            https://pytest.org
d81f3d
Source0:        %{pypi_source}
d81f3d
d81f3d
BuildArch:      noarch
d81f3d
BuildRequires:  pyproject-rpm-macros
d81f3d
d81f3d
%description
d81f3d
py.test provides simple, yet powerful testing for Python.
d81f3d
d81f3d
d81f3d
%package -n python3-%{pypi_name}
d81f3d
Summary:        %{summary}
d81f3d
%{?python_provide:%python_provide python3-%{pypi_name}}
d81f3d
d81f3d
%description -n python3-%{pypi_name}
d81f3d
py.test provides simple, yet powerful testing for Python.
d81f3d
d81f3d
d81f3d
%prep
d81f3d
%autosetup -p1 -n %{pypi_name}-%{version}
d81f3d
d81f3d
d81f3d
%generate_buildrequires
d6e6bb
%pyproject_buildrequires -r -x testing
d81f3d
d81f3d
d81f3d
%build
d81f3d
%pyproject_wheel
d81f3d
d81f3d
d81f3d
%install
d81f3d
%pyproject_install
d81f3d
d6e6bb
%check
d6e6bb
# Only run one test (which uses a test-only dependency, hypothesis).
d6e6bb
# (Unfortunately, some other tests still fail.)
d6e6bb
export PYTHONPATH=%{buildroot}%{python3_sitelib}
d6e6bb
%{__python3} -m pytest -k metafunc
d6e6bb
d81f3d
d81f3d
%files -n python3-%{pypi_name}
d81f3d
%doc README.rst
d81f3d
%doc CHANGELOG.rst
d81f3d
%license LICENSE
d81f3d
%{_bindir}/pytest
d81f3d
%{_bindir}/py.test
d81f3d
%{python3_sitelib}/pytest-*.dist-info/
d81f3d
%{python3_sitelib}/_pytest/
d81f3d
%{python3_sitelib}/pytest.py
d81f3d
%{python3_sitelib}/__pycache__/pytest.*