diff --git a/python-moban-ansible.changes b/python-moban-ansible.changes index 0602fad..2ba31fd 100644 --- a/python-moban-ansible.changes +++ b/python-moban-ansible.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Aug 19 06:53:34 UTC 2022 - Steve Kowalik + +- Add patch remove-mock.patch: + * Use unittest.mock, rather than mock. + ------------------------------------------------------------------- Thu Sep 24 08:40:44 UTC 2020 - pgajdos@suse.com diff --git a/python-moban-ansible.spec b/python-moban-ansible.spec index d58315b..1364ba0 100644 --- a/python-moban-ansible.spec +++ b/python-moban-ansible.spec @@ -1,7 +1,7 @@ # -# spec file for package python-moban-ansible +# spec file # -# Copyright (c) 2020 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 @@ -34,12 +34,11 @@ Version: 0.0.2 Release: 0 Summary: Ansible filters, tests and utility functions for moban users License: BSD-3-Clause -Group: Development/Languages/Python URL: https://github.com/moremoban/moban-ansible Source: https://files.pythonhosted.org/packages/source/m/moban-ansible/moban-ansible-%{version}.tar.gz # https://github.com/moremoban/moban-ansible/pull/2 -Patch0: python-moban-ansible-remove-nose.patch -BuildRequires: %{python_module devel} +Patch0: python-moban-ansible-remove-nose.patch +Patch1: remove-mock.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros @@ -49,7 +48,6 @@ BuildArch: noarch %if %{with test} BuildRequires: %{python_module moban >= 0.8.1} BuildRequires: %{python_module pytest} -BuildRequires: %{python_module mock} %endif # /SECTION %python_subpackages @@ -58,8 +56,7 @@ BuildRequires: %{python_module mock} Ansible filters, tests and utility functions for moban users %prep -%setup -q -n moban-ansible-%{version} -%patch0 -p1 +%autosetup -p1 -n moban-ansible-%{version} %if !%{with test} %build diff --git a/remove-mock.patch b/remove-mock.patch new file mode 100644 index 0000000..6fc11dc --- /dev/null +++ b/remove-mock.patch @@ -0,0 +1,13 @@ +Index: moban-ansible-0.0.2/tests/utils.py +=================================================================== +--- moban-ansible-0.0.2.orig/tests/utils.py ++++ moban-ansible-0.0.2/tests/utils.py +@@ -2,7 +2,7 @@ import os + import sys + from textwrap import dedent + +-from mock import patch ++from unittest.mock import patch + import unittest + + from moban.main import main