You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
python-pytest-cov/python-pytest-cov.spec

126 lines
3.6 KiB

%if 0%{?rhel} && 0%{?rhel} <= 7
11 years ago
%{!?__python2: %global __python2 /usr/bin/python2}
%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
%{!?python2_sitearch: %global python2_sitearch %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
%else
%global with_python3 1
%endif
%global srcname pytest-cov
Name: python-%{srcname}
9 years ago
Version: 2.2.0
Release: 2%{?dist}
11 years ago
Summary: Pytest plugin for coverage reporting
License: MIT
URL: https://pypi.python.org/pypi/%{srcname}
Source0: https://pypi.python.org/packages/source/p/%{srcname}/%{srcname}-%{version}.tar.gz
# Skip xdist tests, not yet packaged
Patch0: python-pytest-cov-xdist.patch
11 years ago
BuildArch: noarch
BuildRequires: python2-devel
BuildRequires: python-setuptools
BuildRequires: pytest
BuildRequires: python-coverage >= 3.7.1
# For tests
BuildRequires: python-process-tests
BuildRequires: python-virtualenv
11 years ago
Requires: pytest
Requires: python-coverage >= 3.7.1
Provides: python2-%{srcname} = %{version}-%{release}
11 years ago
%description
Py.test plugin for coverage reporting with support for both centralised and
distributed testing, including subprocesses and multiprocessing for Python 2.
%if 0%{?with_python3}
%package -n python3-%{srcname}
Summary: Pytest plugin for coverage reporting
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-pytest
BuildRequires: python3-coverage >= 3.7.1
# For tests
BuildRequires: python3-process-tests
BuildRequires: python3-virtualenv
11 years ago
Requires: python3-pytest
Requires: python3-coverage >= 3.7.1
11 years ago
%description -n python3-%{srcname}
Py.test plugin for coverage reporting with support for both centralised and
distributed testing, including subprocesses and multiprocessing for Python 3.
%endif # with_python3
%prep
%setup -q -n %{srcname}-%{version}
%patch0 -p1 -b .xdist
11 years ago
rm -rf *.egg-info
%build
%py2_build
11 years ago
%if 0%{?with_python3}
%py3_build
11 years ago
%endif # with_python3
%install
%if 0%{?with_python3}
%py3_install
11 years ago
%endif # with_python3
%py2_install
11 years ago
#%check
#PYTHONPATH=%{buildroot}%{python2_sitelib}:$PWD/tests py.test-%{python2_version} -vv
#
#%if 0%{?with_python3}
#PYTHONPATH=%{buildroot}%{python3_sitelib}:$PWD/tests py.test-%{python3_version} -vv
#%endif # with_python3
11 years ago
%files
%license LICENSE
%doc AUTHORS.rst CHANGELOG.rst CONTRIBUTING.rst README.rst
11 years ago
%{python2_sitelib}/*
%if 0%{?with_python3}
%files -n python3-%{srcname}
%license LICENSE
%doc AUTHORS.rst CHANGELOG.rst CONTRIBUTING.rst README.rst
11 years ago
%{python3_sitelib}/*
%endif # with_python3
%changelog
* Fri Nov 06 2015 Robert Kuska <rkuska@redhat.com> - 2.2.0-2
- Rebuilt for Python3.5 rebuild
- Skip tests for a python3 rebuild as it seems to be env failure
9 years ago
* Mon Oct 5 2015 Orion Poplawski <orion@cora.nwra.com> - 2.2.0-1
- Update to 2.2.0
* Mon Sep 14 2015 Orion Poplawski <orion@cora.nwra.com> - 2.1.0-2
- Modernize spec
- Run tests properly, skipping xdist tests for now
* Mon Sep 14 2015 Tomas Tomecek <ttomecek@redhat.com> - 2.1.0-1
- upstream release 2.1.0
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Tue May 27 2014 Orion Poplawski <orion@cora.nwra.com> - 1.6-2
- Rebuild for Python 3.4
11 years ago
* Tue Feb 25 2014 Orion Poplawski <orion@cora.nwra.com> - 1.6-1
- Initial package