diff --git a/pytest6.patch b/pytest6.patch new file mode 100644 index 0000000..1fed93b --- /dev/null +++ b/pytest6.patch @@ -0,0 +1,13 @@ +Index: Babel-2.8.0/conftest.py +=================================================================== +--- Babel-2.8.0.orig/conftest.py ++++ Babel-2.8.0/conftest.py +@@ -8,4 +8,7 @@ babel_path = local(__file__).dirpath().j + def pytest_collect_file(path, parent): + if babel_path.common(path) == babel_path: + if path.ext == ".py": +- return DoctestModule(path, parent) ++ try: ++ return DoctestModule.from_parent(parent, fspath=path) ++ except AttributeError: ++ return DoctestModule(path, parent) diff --git a/python-Babel.changes b/python-Babel.changes index 3d49340..39944a4 100644 --- a/python-Babel.changes +++ b/python-Babel.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Aug 27 12:38:55 UTC 2020 - Marketa Calabkova + +- Add patch to fix building with new pytest 6.0.1: + * pytest6.patch + ------------------------------------------------------------------- Tue May 19 10:38:24 UTC 2020 - Tomáš Chvátal diff --git a/python-Babel.spec b/python-Babel.spec index fa8b2cc..cf1eac7 100644 --- a/python-Babel.spec +++ b/python-Babel.spec @@ -26,6 +26,7 @@ License: BSD-3-Clause URL: http://babel.pocoo.org/ Source: https://files.pythonhosted.org/packages/source/B/Babel/Babel-%{version}.tar.gz Patch0: python383.patch +Patch1: pytest6.patch BuildRequires: %{python_module freezegun} BuildRequires: %{python_module py >= 1.4.14} BuildRequires: %{python_module pytest >= 2.3.5} @@ -53,6 +54,7 @@ A collection of tools for internationalizing Python applications. %prep %setup -q -n Babel-%{version} %patch0 -p1 +%patch1 -p1 %build %python_build