File python-pyramid_deform.spec of Package python-pyramid_deform

#
# spec file for package python-pyramid_deform
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2013 LISA GmbH, Bingen, 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-%{**}}
Name:           python-pyramid_deform
Version:        0.2
Release:        0
Url:            http://docs.pylonsproject.org
Summary:        Bindings to the Deform library for the Pyramid web framework
License:        BSD-4-Clause and ZPL-2.1 and MIT
Group:          Development/Languages/Python
Source:         https://files.pythonhosted.org/packages/source//p/pyramid_deform/pyramid_deform-%{version}.tar.gz
BuildRequires:  %{python_module deform} >= 0.8.1
BuildRequires:  %{python_module devel}
BuildRequires:  %{python_module pyramid} >= 1.4
BuildRequires:  %{python_module setuptools}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
# Documentation requirements:
BuildRequires:  python3-Sphinx
BuildRequires:  python3-pylons-sphinx-themes
# Testing requirements:
# test requirements
BuildRequires:  %{python_module coverage}
BuildRequires:  %{python_module hupper}
BuildRequires:  %{python_module mock}
BuildRequires:  %{python_module nose}
BuildRequires:  %{python_module plaster-pastedeploy}
BuildRequires:  %{python_module plaster}
Requires:       python-deform >= 0.8.1
Requires:       python-pyramid
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

%python_subpackages

%description
pyramid_deform provides bindings for the Pyramid web framework to the Deform form library.

For more information, see the documentation in the -doc package or at
http://docs.pylonsproject.org/projects/pyramid_deform

%package -n %{name}-doc
Summary:        Bindings to the Deform library for the Pyramid web framework
Group:          Development/Languages/Python
Requires:       %{name} = %{version}

%description -n %{name}-doc
This package contains documentation files for %{name}.

%prep
%setup -q -n pyramid_deform-%{version}

%build
%python_build
python3 setup.py build_sphinx && rm -f build/sphinx/html/.buildinfo

%install
%python_install
%python_expand %fdupes -s %{buildroot}%{$python_sitelib}

%check
%python_exec setup.py nosetests --with-coverage

%files %python_files
%defattr(-,root,root,-)
%if 0%{?leap_version} >= 420200 || 0%{?suse_version} > 1320
%license LICENSE.txt
%else
%doc LICENSE.txt
%endif
%doc CHANGES.txt CONTRIBUTORS.txt COPYRIGHT.txt README.rst TODO.txt
%{python_sitelib}/*

%files -n %{name}-doc
%defattr(-,root,root,-)
%doc build/sphinx/html

%changelog
openSUSE Build Service is sponsored by