From 99b8f93569a677c7dd010bb26bc860e7820cd4c0cda71bf851ce5ea144953850 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Tue, 10 Aug 2021 07:52:37 +0000 Subject: [PATCH] - Add skip-test_keepalive_ping_with_no_ping_timeout.patch for gh#aaugustin/websockets#1026. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-websockets?expand=0&rev=28 --- python-websockets.changes | 2 ++ python-websockets.spec | 6 +++++- ..._keepalive_ping_with_no_ping_timeout.patch | 21 +++++++++++++++++++ 3 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 skip-test_keepalive_ping_with_no_ping_timeout.patch diff --git a/python-websockets.changes b/python-websockets.changes index 52ee7bc..3be03de 100644 --- a/python-websockets.changes +++ b/python-websockets.changes @@ -2,6 +2,8 @@ Tue Aug 10 07:18:14 UTC 2021 - Matej Cepl - Use %pyunittest macro instead of doing it on our own. +- Add skip-test_keepalive_ping_with_no_ping_timeout.patch for + gh#aaugustin/websockets#1026. ------------------------------------------------------------------- Sun Jun 6 12:00:22 UTC 2021 - Dirk Müller diff --git a/python-websockets.spec b/python-websockets.spec index 30c42b1..7b74d11 100644 --- a/python-websockets.spec +++ b/python-websockets.spec @@ -26,7 +26,11 @@ License: BSD-3-Clause Group: Development/Languages/Python URL: https://github.com/aaugustin/websockets Source: https://github.com/aaugustin/websockets/archive/%{version}.tar.gz +# PATCH-FIX-UPSTREAM skip-test_keepalive_ping_with_no_ping_timeout.patch gh#aaugustin/websockets#1026 mcepl@suse.com +# Skip test test_keepalive_ping_with_no_ping_timeout +Patch0: skip-test_keepalive_ping_with_no_ping_timeout.patch BuildRequires: %{python_module devel} +BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros @@ -42,7 +46,7 @@ it provides an API based on coroutines, making it easy to write highly concurrent applications. %prep -%setup -q -n websockets-%{version} +%autosetup -p1 -n websockets-%{version} %build export CFLAGS="%{optflags}" diff --git a/skip-test_keepalive_ping_with_no_ping_timeout.patch b/skip-test_keepalive_ping_with_no_ping_timeout.patch new file mode 100644 index 0000000..f91a7e7 --- /dev/null +++ b/skip-test_keepalive_ping_with_no_ping_timeout.patch @@ -0,0 +1,21 @@ +--- + tests/legacy/test_protocol.py | 2 ++ + 1 file changed, 2 insertions(+) + +--- a/tests/legacy/test_protocol.py ++++ b/tests/legacy/test_protocol.py +@@ -1,5 +1,6 @@ + import asyncio + import contextlib ++import platform + import sys + import unittest + import unittest.mock +@@ -1189,6 +1190,7 @@ class CommonTests: + self.loop.run_until_complete(asyncio.sleep(4 * MS)) + self.assertNoFrameSent() + ++ @unittest.skipIf(platform.processor() == 'x86_64', 'gh#aaugustin/websockets#1026') + def test_keepalive_ping_with_no_ping_timeout(self): + self.restart_protocol_with_keepalive_ping(ping_timeout=None) +