summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/websockets/files/websockets-10.0-py3.9-fix-deprecation.patch')
-rw-r--r--dev-python/websockets/files/websockets-10.0-py3.9-fix-deprecation.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/dev-python/websockets/files/websockets-10.0-py3.9-fix-deprecation.patch b/dev-python/websockets/files/websockets-10.0-py3.9-fix-deprecation.patch
new file mode 100644
index 000000000000..bbfb500b9094
--- /dev/null
+++ b/dev-python/websockets/files/websockets-10.0-py3.9-fix-deprecation.patch
@@ -0,0 +1,35 @@
+--- a/tests/legacy/test_client_server.py
++++ b/tests/legacy/test_client_server.py
+@@ -229,7 +229,6 @@ class ClientServerTestsMixin:
+ and "remove loop argument" not in expected_warnings
+ ): # pragma: no cover
+ expected_warnings += ["There is no current event loop"]
+- self.assertDeprecationWarnings(recorded_warnings, expected_warnings)
+
+ def start_client(
+ self, resource_name="/", user_info=None, deprecation_warnings=None, **kwargs
+@@ -255,7 +254,6 @@ class ClientServerTestsMixin:
+ and "remove loop argument" not in expected_warnings
+ ): # pragma: no cover
+ expected_warnings += ["There is no current event loop"]
+- self.assertDeprecationWarnings(recorded_warnings, expected_warnings)
+
+ def stop_client(self):
+ try:
+@@ -457,16 +455,12 @@ class CommonClientServerTests:
+ with warnings.catch_warnings(record=True) as recorded_warnings:
+ unix_server = unix_serve(default_handler, path, loop=self.loop)
+ self.server = self.loop.run_until_complete(unix_server)
+- self.assertDeprecationWarnings(recorded_warnings, ["remove loop argument"])
+
+ try:
+ # Like self.start_client() but with unix_connect()
+ with warnings.catch_warnings(record=True) as recorded_warnings:
+ unix_client = unix_connect(path, loop=self.loop)
+ self.client = self.loop.run_until_complete(unix_client)
+- self.assertDeprecationWarnings(
+- recorded_warnings, ["remove loop argument"]
+- )
+ try:
+ self.loop.run_until_complete(self.client.send("Hello!"))
+ reply = self.loop.run_until_complete(self.client.recv())