File python-pyramid_handlers.spec of Package python-pyramid_handlers

#
# spec file for package python-pyramid_handlers
#
# Copyright (c) 2020 SUSE LLC
# 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 https://bugs.opensuse.org/
#


%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name:           python-pyramid_handlers
Version:        0.5
Release:        0
Summary:        Pyramid handlers emulate Pylons 1 controllers
License:        BSD-4-Clause AND ZPL-2.1 AND MIT
Group:          Development/Languages/Python
URL:            http://docs.pylonsproject.org
Source:         https://files.pythonhosted.org/packages/source/p/pyramid_handlers/pyramid_handlers-%{version}.tar.gz
Source1:        fetch-intersphinx-files.sh
Source2:        pyramid.inv
# Testing requirements:
#BuildRequires:  %%{python_module WebTest}
BuildRequires:  %{python_module coverage}
BuildRequires:  %{python_module devel}
#BuildRequires:  %%{python_module hupper}
BuildRequires:  %{python_module nose}
BuildRequires:  %{python_module pyramid_zcml} >= 0.9.2
BuildRequires:  %{python_module pyramid} >= 1.0
BuildRequires:  %{python_module setuptools}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires:       python-pyramid >= 1.0
Requires:       python-pyramid_zcml >= 0.9.2
#BuildRequires:  %%{python_module plaster-pastedeploy}
#BuildRequires:  %%{python_module plaster}
#BuildRequires:  %%{python_module pyramid_mako}
BuildArch:      noarch
%python_subpackages

%description
pyramid_handlers is a package which allows Pyramid to largely emulate the
functionality of Pylons 1 "controllers". Handlers are a synthesis of Pyramid
url dispatch and method introspection of a view class that makes it easier to
create bundles of view logic which reacts to particular route patterns.

See http://docs.pylonsproject.org/projects/pyramid_handlers/en/latest/ for
detailed documentation.

%prep
%setup -q -n pyramid_handlers-%{version}
# patch in local intersphinx file
# sed -i "s|'\(.*\)', None|'\1', 'pyramid.inv'|g" docs/conf.py
# cp %%SOURCE2 docs/

%build
%python_build

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

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

%files %python_files
%defattr(-,root,root,-)
%license LICENSE.txt
%doc CHANGES.txt CONTRIBUTORS.txt README.rst
%{python_sitelib}/*

%changelog