diff --git a/pytest5.patch b/pytest5.patch new file mode 100644 index 0000000..caf318b --- /dev/null +++ b/pytest5.patch @@ -0,0 +1,23 @@ +From 6f920b154ad4e013ac60e4193ac4606fca20be73 Mon Sep 17 00:00:00 2001 +From: "dependabot-preview[bot]" + <27856297+dependabot-preview[bot]@users.noreply.github.com> +Date: Tue, 2 Jul 2019 20:56:53 +0300 +Subject: [PATCH] Bump pytest from 4.6.3 to 5.0.0 (#3879) + +--- + tests/test_worker.py | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/tests/test_worker.py b/tests/test_worker.py +index 675b37968..1106820fb 100644 +--- a/tests/test_worker.py ++++ b/tests/test_worker.py +@@ -195,7 +195,7 @@ def test__get_valid_log_format_ok(worker, source, result) -> None: + def test__get_valid_log_format_exc(worker) -> None: + with pytest.raises(ValueError) as exc: + worker._get_valid_log_format(WRONG_LOG_FORMAT) +- assert '%(name)s' in str(exc) ++ assert '%(name)s' in str(exc.value) + + + async def test__run_ok_parent_changed(worker, loop, diff --git a/python-aiohttp.changes b/python-aiohttp.changes index 3ab0e36..72d64b4 100644 --- a/python-aiohttp.changes +++ b/python-aiohttp.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Aug 22 09:27:05 UTC 2019 - Tomáš Chvátal + +- Add patch to work well with pytest 5: + * pytest5.patch + ------------------------------------------------------------------- Tue Jun 4 14:47:20 UTC 2019 - Ondřej Súkup diff --git a/python-aiohttp.spec b/python-aiohttp.spec index 3c0b3d2..3144556 100644 --- a/python-aiohttp.spec +++ b/python-aiohttp.spec @@ -26,6 +26,7 @@ License: Apache-2.0 Group: Development/Languages/Python URL: https://github.com/aio-libs/aiohttp Source: https://files.pythonhosted.org/packages/source/a/aiohttp/aiohttp-%{version}.tar.gz +Patch0: pytest5.patch BuildRequires: %{python_module Cython} BuildRequires: %{python_module async_timeout >= 3.0} BuildRequires: %{python_module attrs >= 17.3.0} @@ -33,12 +34,6 @@ BuildRequires: %{python_module chardet >= 2.0} BuildRequires: %{python_module devel >= 3.5.3} BuildRequires: %{python_module multidict >= 4.0} BuildRequires: %{python_module setuptools} -%if 0%{suse_version} < 1550 -BuildRequires: %{python_module idna_ssl >= 1.0} -BuildRequires: %{python_module typing_extensions >= 3.6.5} -Requires: python-idna_ssl -Requires: python-typing_extensions -%endif BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python >= 3.5.3 @@ -49,10 +44,15 @@ Requires: python-chardet >= 2.0 Requires: python-gunicorn Requires: python-multidict >= 4.0 Requires: python-yarl >= 1.0 -Requires: python-yarl >= 1.0 Recommends: python-aiodns Recommends: python-cChardet Suggests: %{name}-doc +%if 0%{?suse_version} < 1550 +BuildRequires: %{python_module idna_ssl >= 1.0} +BuildRequires: %{python_module typing_extensions >= 3.6.5} +Requires: python-idna_ssl +Requires: python-typing_extensions +%endif # SECTION test requirements BuildRequires: %{python_module async_generator} BuildRequires: %{python_module brotlipy} @@ -94,6 +94,7 @@ HTML documentation on the API and examples for %{name}. %prep %setup -q -n aiohttp-%{version} +%patch0 -p1 %build export CFLAGS="%{optflags}"