File python-piston-mini-client.spec of Package python-piston-mini-client

#
# spec file for package python-piston-mini-client
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define oldpython python
%bcond_with     test
Name:           python-piston-mini-client
Version:        0.7.5
Release:        0
Summary:        A small package to consume Django-Piston web services
License:        LGPL-3.0
Group:          Development/Languages/Python
Url:            https://launchpad.net/piston-mini-client
Source:         https://files.pythonhosted.org/packages/source/p/piston-mini-client/piston-mini-client-%{version}.tar.gz
BuildRequires:  %{python_module devel}
BuildRequires:  %{python_module setuptools}
BuildRequires:  python-rpm-macros
%if %{with test}
BuildRequires:  %{python_module Sphinx}
BuildRequires:  %{python_module httplib2}
BuildRequires:  %{python_module mock}
BuildRequires:  %{python_module nose}
BuildRequires:  %{python_module oauthlib}
BuildRequires:  %{python_module pep8}
BuildRequires:  python3-tox
%endif
Requires:       python-oauthlib
%ifpython2
Provides:       %{oldpython}-piston-mini = %{version}
Obsoletes:      %{oldpython}-piston-mini < %{version}
%endif
BuildArch:      noarch
%python_subpackages

%description
A small generic library for writing clients for Django's Piston REST APIs.

%prep
%setup -q -n piston-mini-client-%{version}

%build
%python_build

%install
%python_install

%if %{with test}
%check
tox --sitepackages --skip-missing-interpreters
%endif

%files %{python_files}
%defattr(-,root,root,-)
%doc LICENSE README
%{python_sitelib}/*

%changelog
openSUSE Build Service is sponsored by