15
0
forked from pool/python-cachey
Tomáš Chvátal
2019-01-24 08:20:27 +00:00
committed by Git OBS Bridge
parent b72188ba45
commit cd61fcd572

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-cachey
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2019 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
@@ -12,34 +12,28 @@
# 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/
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_without test
Name: python-cachey
Version: 0.1.1
Release: 0
Summary: Caching mindful of computation/storage costs
License: BSD-3-Clause
Group: Development/Languages/Python
Url: http://github.com/mrocklin/cachey/
URL: http://github.com/mrocklin/cachey/
Source: https://files.pythonhosted.org/packages/source/c/cachey/cachey-%{version}.tar.gz
# PATCH-FIX-UPSTREAM fix_cache_clear.patch - fix unit test error
Patch0: fix_cache_clear.patch
BuildRequires: %{python_module HeapDict}
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
%if %{with test}
BuildRequires: %{python_module pytest}
%endif
Requires: python-HeapDict
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%python_subpackages
%description
@@ -69,16 +63,12 @@ roughly linear amplification of repeated results.
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%if %{with test}
%check
%{python_expand export PYTHONPATH=%{buildroot}%{$python_sitelib}
py.test-%{$python_bin_suffix}
}
%endif
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} py.test-%{$python_bin_suffix} -v
%files %{python_files}
%defattr(-,root,root,-)
%doc LICENSE.txt README.md
%license LICENSE.txt
%doc README.md
%{python_sitelib}/*
%changelog