[packages/python3-pytest-mock] - up to 3.14.0
baggins
baggins at pld-linux.org
Thu Mar 27 23:07:57 CET 2025
commit ebfd466c7ce6c6f529c3a27d50ddaba6d70da04b
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Fri Mar 28 00:07:56 2025 +0100
- up to 3.14.0
pytest-mock-tests.patch | 33 ---------------------------------
python3-pytest-mock.spec | 18 ++++++++----------
2 files changed, 8 insertions(+), 43 deletions(-)
---
diff --git a/python3-pytest-mock.spec b/python3-pytest-mock.spec
index 4a36584..677ef46 100644
--- a/python3-pytest-mock.spec
+++ b/python3-pytest-mock.spec
@@ -5,18 +5,17 @@
Summary: Thin-wrapper around the mock package for easier use with py.test
Summary(pl.UTF-8): Cienka warstwa obudowująca pakiet mock, ułatwiająca używanie wraz z py.test
Name: python3-pytest-mock
-Version: 3.10.0
-Release: 3
+Version: 3.14.0
+Release: 1
License: MIT
Group: Libraries/Python
#Source0Download: https://pypi.org/simple/pytest-mock/
Source0: https://files.pythonhosted.org/packages/source/p/pytest-mock/pytest-mock-%{version}.tar.gz
-# Source0-md5: 29c685fb54fbac80aae0e551bcbaab31
-Patch0: pytest-mock-tests.patch
+# Source0-md5: c22f3c24300091f503258d1ba5159551
URL: https://pypi.org/project/pytest-mock/
BuildRequires: python3-modules >= 1:3.7
-BuildRequires: python3-setuptools
-BuildRequires: python3-setuptools_scm
+BuildRequires: python3-build
+BuildRequires: python3-installer
%if %{with tests}
BuildRequires: python3-pytest >= 5.0
BuildRequires: python3-pytest-asyncio
@@ -41,10 +40,9 @@ pozwalający nie martwić się o wycofywanie łat na końcu testu.
%prep
%setup -q -n pytest-mock-%{version}
-%patch -P 0 -p1
%build
-%py3_build
+%py3_build_pyproject
%if %{with tests}
PYTHONPATH=$(pwd)/src \
@@ -56,7 +54,7 @@ PYTEST_PLUGINS="pytest_asyncio.plugin,pytest_mock" \
%install
rm -rf $RPM_BUILD_ROOT
-%py3_install
+%py3_install_pyproject
%clean
rm -rf $RPM_BUILD_ROOT
@@ -65,4 +63,4 @@ rm -rf $RPM_BUILD_ROOT
%defattr(644,root,root,755)
%doc CHANGELOG.rst LICENSE README.rst
%{py3_sitescriptdir}/pytest_mock
-%{py3_sitescriptdir}/pytest_mock-%{version}-py*.egg-info
+%{py3_sitescriptdir}/pytest_mock-%{version}.dist-info
diff --git a/pytest-mock-tests.patch b/pytest-mock-tests.patch
deleted file mode 100644
index 6ba9f8f..0000000
--- a/pytest-mock-tests.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-"more diff" vs "full diff"
---- pytest-mock-3.10.0/tests/test_pytest_mock.py.orig 2022-10-05 20:52:25.000000000 +0200
-+++ pytest-mock-3.10.0/tests/test_pytest_mock.py 2022-10-24 06:26:54.219495582 +0200
-@@ -773,12 +773,12 @@ def test_detailed_introspection(testdir:
- "*Args:",
- "*assert ('fo',) == ('',)",
- "*At index 0 diff: 'fo' != ''*",
-- "*Use -v to get more diff*",
-+ "*Use -v to get * diff*",
- "*Kwargs:*",
- "*assert {} == {'bar': 4}*",
- "*Right contains* more item*",
- "*{'bar': 4}*",
-- "*Use -v to get more diff*",
-+ "*Use -v to get * diff*",
- ]
- result.stdout.fnmatch_lines(expected_lines)
-
-@@ -814,12 +814,12 @@ def test_detailed_introspection_async(te
- "*Args:",
- "*assert ('fo',) == ('',)",
- "*At index 0 diff: 'fo' != ''*",
-- "*Use -v to get more diff*",
-+ "*Use -v to get * diff*",
- "*Kwargs:*",
- "*assert {} == {'bar': 4}*",
- "*Right contains* more item*",
- "*{'bar': 4}*",
-- "*Use -v to get more diff*",
-+ "*Use -v to get * diff*",
- ]
- result.stdout.fnmatch_lines(expected_lines)
-
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python3-pytest-mock.git/commitdiff/ebfd466c7ce6c6f529c3a27d50ddaba6d70da04b
More information about the pld-cvs-commit
mailing list