From 77c9ad5d2979e515f368e8043e82411323c66952c83cd32dfed4e564c86fbce4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Wed, 20 Apr 2022 07:47:24 +0000 Subject: [PATCH] Accepting request 970990 from home:pgajdos:python - do not require python-mock for build OBS-URL: https://build.opensuse.org/request/show/970990 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-transaction?expand=0&rev=43 --- python-transaction.changes | 5 +++++ python-transaction.spec | 9 +++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/python-transaction.changes b/python-transaction.changes index c2fea2e..04cf991 100644 --- a/python-transaction.changes +++ b/python-transaction.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Apr 20 07:35:20 UTC 2022 - pgajdos@suse.com + +- do not require python-mock for build + ------------------------------------------------------------------- Wed Jan 13 14:19:23 UTC 2021 - pgajdos@suse.com diff --git a/python-transaction.spec b/python-transaction.spec index 83eda77..354e8bd 100644 --- a/python-transaction.spec +++ b/python-transaction.spec @@ -1,7 +1,7 @@ # # spec file for package python-transaction # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -24,15 +24,14 @@ Summary: Transaction management for Python License: ZPL-2.1 URL: https://github.com/zopefoundation/transaction Source: https://files.pythonhosted.org/packages/source/t/transaction/transaction-%{version}.tar.gz -BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} -BuildRequires: %{python_module zope.interface} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-zope.interface BuildArch: noarch # SECTION Test requirements -BuildRequires: %{python_module mock} +BuildRequires: %{python_module pytest} +BuildRequires: %{python_module zope.interface} # /SECTION %python_subpackages @@ -58,6 +57,8 @@ rm -rf transaction.egg-info %python_expand %fdupes %{buildroot}%{$python_sitelib} %check +# https://github.com/zopefoundation/zdaemon/issues/28#issuecomment-1102754818 +sed -i 's:import mock:from unittest import mock:' src/transaction/tests/test__manager.py %pytest %files %{python_files}