2021-12-04 15:24:23 +00:00
#
# spec file for package python-cornice
#
2024-02-08 11:27:55 +00:00
# Copyright (c) 2024 SUSE LLC
2021-12-04 15:24:23 +00:00
#
# 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-%{**}}
Name : python-cornice
2022-01-07 18:57:18 +00:00
Version : 6.0.1
2021-12-04 15:24:23 +00:00
Release : 0
Summary : Define Web Services in Pyramid
License : MPL-2.0
URL : https://cornice.readthedocs.io/
# use github URL for docs and tests
Source : https://github.com/Cornices/cornice/archive/refs/tags/%{version} .tar.gz#/%{name}-%{version}.tar.gz
#Source: https://files.pythonhosted.org/packages/source/c/cornice/cornice-%%{version}.tar.gz
2024-02-08 11:27:55 +00:00
# PATCH-FIX-UPSTREAM fix-python-312-test.patch -- from https://github.com/Cornices/cornice/commit/61e209d9bc946563bd7dc645a8a65f14d94246f1 see https://github.com/Cornices/cornice/issues/581
Patch0 : https://github.com/Cornices/cornice/commit/61e209d9bc946563bd7dc645a8a65f14d94246f1.patch#/fix-python-312-test.patch
2021-12-04 15:24:23 +00:00
BuildRequires : %{python_module setuptools}
BuildRequires : fdupes
2024-02-08 11:27:55 +00:00
BuildRequires : python-rpm-macros
2021-12-04 15:24:23 +00:00
# SECTION tests
BuildRequires : %{python_module Sphinx}
BuildRequires : %{python_module WebTest}
BuildRequires : %{python_module colander >= 1.0~b1}
BuildRequires : %{python_module coverage}
2022-01-07 18:57:18 +00:00
BuildRequires : %{python_module marshmallow >= 3.0.0}
BuildRequires : %{python_module pyramid >= 1.7}
2021-12-04 15:24:23 +00:00
BuildRequires : %{python_module pytest-cov}
2022-01-07 18:57:18 +00:00
BuildRequires : %{python_module pytest}
2021-12-04 15:24:23 +00:00
BuildRequires : %{python_module simplejson}
# /SECTION
Requires : python-pyramid >= 1.7
Requires : python-venusian
BuildArch : noarch
%python_subpackages
%description
Provides helpers to build & document Web Services with Pyramid.
%prep
%setup -q -n cornice-%{version}
2024-02-08 11:27:55 +00:00
%patch 0 -p1
2021-12-04 15:24:23 +00:00
chmod -x docs/source/tutorial.rst
%build
%python_build
# building docs requires unavailable mozilla-sphinx-theme
%install
%python_install
%python_expand %fdupes %{buildroot} %{$python_sitelib}
%check
%pytest
%files %{python_files}
%{python_sitelib} /*
%doc README.rst CHANGES.txt docs/
%license LICENSE
%changelog