forked from pool/python-pytest-verbose-parametrize
Accepting request 945369 from devel:languages:python:pytest
- Add Iterable-collections.patch to avoid Python 3.10 incompatibility (gh#man-group/pytest-plugins#197). OBS-URL: https://build.opensuse.org/request/show/945369 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pytest-verbose-parametrize?expand=0&rev=4
This commit is contained in:
15
Iterable-collections.patch
Normal file
15
Iterable-collections.patch
Normal file
@@ -0,0 +1,15 @@
|
||||
---
|
||||
pytest_verbose_parametrize.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
--- a/pytest_verbose_parametrize.py
|
||||
+++ b/pytest_verbose_parametrize.py
|
||||
@@ -1,4 +1,7 @@
|
||||
-from collections import Iterable
|
||||
+try:
|
||||
+ from collections.abc import Iterable
|
||||
+except (ImportError, ModuleNotFoundError):
|
||||
+ from collections import Iterable
|
||||
from six import string_types, text_type
|
||||
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Jan 10 16:09:01 UTC 2022 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Add Iterable-collections.patch to avoid Python 3.10
|
||||
incompatibility (gh#man-group/pytest-plugins#197).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 22 09:05:47 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-pytest-verbose-parametrize
|
||||
#
|
||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# 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
|
||||
@@ -25,6 +25,10 @@ License: MIT
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/manahl/pytest-plugins
|
||||
Source: https://files.pythonhosted.org/packages/source/p/pytest-verbose-parametrize/pytest-verbose-parametrize-%{version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAM Iterable-collections.patch gh#man-group/pytest-plugins#197 mcepl@suse.com
|
||||
# Python 3.10 finally really killed collections class, which are now in
|
||||
# collections.abc
|
||||
Patch0: Iterable-collections.patch
|
||||
BuildRequires: %{python_module setuptools-git}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: fdupes
|
||||
@@ -46,6 +50,8 @@ More descriptive output for parametrized py.test tests.
|
||||
|
||||
%prep
|
||||
%setup -q -n pytest-verbose-parametrize-%{version}
|
||||
%autopatch -p1
|
||||
|
||||
# we can't do integration tests as py2 and py3 can be different versions
|
||||
# and the script simply calls $bindir/pytest
|
||||
rm tests/integration/test_verbose_parametrize.py
|
||||
|
||||
Reference in New Issue
Block a user