Accepting request 319404 from home:TheBlackCat:branches:devel:languages:python

Make tests conditional to avoid dependency loop.

OBS-URL: https://build.opensuse.org/request/show/319404
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pip?expand=0&rev=37
This commit is contained in:
Todd R 2015-07-29 13:08:31 +00:00 committed by Git OBS Bridge
parent 81b7367b7f
commit 04982ea520
2 changed files with 12 additions and 0 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Wed Jul 29 13:01:56 UTC 2015 - toddrme2178@gmail.com
- Make tests conditional to avoid dependency loop.
-------------------------------------------------------------------
Wed Mar 18 17:30:07 UTC 2015 - tbechtold@suse.com

View File

@ -15,6 +15,9 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# NOTE(saschpe): git invocation and pythonpath issues with testrepository
# enable testing with a build conditional (off by default):
%bcond_with test
Name: python-pip
Version: 6.0.8
@ -27,11 +30,13 @@ Source: http://pypi.python.org/packages/source/p/pip/pip-%{version}.tar.
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel
BuildRequires: python-setuptools
%if %{with test}
# Test requirements:
BuildRequires: python-mock
BuildRequires: python-pytest
BuildRequires: python-scripttest >= 1.3
BuildRequires: python-virtualenv >= 1.10
%endif
Requires: python-setuptools
Requires: python-xml
Requires(post): update-alternatives
@ -61,8 +66,10 @@ python setup.py install --prefix=%{_prefix} --root=%{buildroot}
rm %{buildroot}%{_bindir}/pip
ln -s %{_bindir}/pip%{py_ver} %{buildroot}%{_bindir}/pip
%if %{with test}
%check
python setup.py test
%endif
%pre
# Since /usr/bin/pip became ghosted to be used with update-alternatives, we have to get rid