Accepting request 499458 from home:sebix:branches:devel:languages:python
singlespec required by Request#498334 OBS-URL: https://build.opensuse.org/request/show/499458 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests-mock?expand=0&rev=12
This commit is contained in:
parent
e42438930b
commit
454fadbebe
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu May 25 15:22:58 UTC 2017 - sebix+novell.com@sebix.at
|
||||||
|
|
||||||
|
- convert to singlespec
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Jan 30 11:04:29 UTC 2017 - tbechtold@suse.com
|
Mon Jan 30 11:04:29 UTC 2017 - tbechtold@suse.com
|
||||||
|
|
||||||
|
@ -16,6 +16,8 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
|
%bcond_without test
|
||||||
Name: python-requests-mock
|
Name: python-requests-mock
|
||||||
Version: 1.2.0
|
Version: 1.2.0
|
||||||
Release: 0
|
Release: 0
|
||||||
@ -23,43 +25,55 @@ Summary: Mock out responses from the requests package
|
|||||||
License: Apache-2.0
|
License: Apache-2.0
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Url: https://requests-mock.readthedocs.org/
|
Url: https://requests-mock.readthedocs.org/
|
||||||
Source: https://pypi.io/packages/source/r/requests-mock/requests-mock-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/r/requests-mock/requests-mock-%{version}.tar.gz
|
||||||
BuildRequires: python-devel
|
BuildRequires: %{python_module Sphinx >= 1.1.2}
|
||||||
BuildRequires: python-fixtures
|
BuildRequires: %{python_module devel}
|
||||||
BuildRequires: python-mock
|
BuildRequires: %{python_module fixtures}
|
||||||
BuildRequires: python-pbr
|
BuildRequires: %{python_module mock}
|
||||||
BuildRequires: python-requests
|
BuildRequires: %{python_module pbr}
|
||||||
BuildRequires: python-six
|
BuildRequires: %{python_module requests}
|
||||||
BuildRequires: python-sphinx >= 1.1.2
|
BuildRequires: %{python_module rpm-macros}
|
||||||
BuildRequires: python-testrepository >= 0.0.18
|
BuildRequires: %{python_module six}
|
||||||
BuildRequires: python-testtools
|
BuildRequires: %{python_module testrepository >= 0.0.18}
|
||||||
|
BuildRequires: %{python_module testtools}
|
||||||
|
BuildRequires: fdupes
|
||||||
|
BuildRequires: python3-dbm
|
||||||
Requires: python-requests >= 1.1
|
Requires: python-requests >= 1.1
|
||||||
Requires: python-six
|
Requires: python-six
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
%ifpython3
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
Requires: python3-dbm
|
||||||
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
|
||||||
%else
|
|
||||||
BuildArch: noarch
|
|
||||||
%endif
|
%endif
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
`requests-mock` provides a building block to stub out the HTTP `requests`_ portions of your testing code.
|
requests-mock provides a building block to stub out the HTTP requests portions of your testing code.
|
||||||
You should checkout the `docs`_ for more information.
|
You should checkout the docs for more information.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n requests-mock-%{version}
|
%setup -q -n requests-mock-%{version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
python setup.py build
|
%python_build
|
||||||
|
|
||||||
%install
|
%install
|
||||||
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
%python_install
|
||||||
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}/mymodule
|
||||||
|
|
||||||
|
%if %{with test}
|
||||||
%check
|
%check
|
||||||
|
mv .testr.conf .testr.conf.orig
|
||||||
|
%{python_expand # first line can't be empty
|
||||||
|
rm -rf .testrepository
|
||||||
|
sed 's/python/$python/' .testr.conf.orig >| .testr.conf
|
||||||
testr init
|
testr init
|
||||||
testr run --parallel
|
testr run --parallel
|
||||||
|
}
|
||||||
|
%endif
|
||||||
|
|
||||||
%files
|
%files %{python_files}
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
%doc AUTHORS README.rst LICENSE ChangeLog
|
%doc AUTHORS README.rst LICENSE ChangeLog
|
||||||
%{python_sitelib}/*
|
%{python_sitelib}/*
|
||||||
|
Loading…
Reference in New Issue
Block a user