]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-38912: fix close before connect callback in test_asyncio SSL tests (GH-22691)
authorJustin Turner Arthur <justinarthur@gmail.com>
Tue, 20 Oct 2020 01:18:57 +0000 (20:18 -0500)
committerGitHub <noreply@github.com>
Tue, 20 Oct 2020 01:18:57 +0000 (21:18 -0400)
Reduces the rate at which the ENV CHANGED failure occurs in test_asyncio SSL tests (due to unclosed transport), but does not 100% resolve it.

Lib/test/test_asyncio/test_events.py
Misc/ACKS

index ef9d6fc48e9f88af8db4d1a1ee50aba11ec17930..b8fe466cd53dfc812b04df79a577ec3d2e225187 100644 (file)
@@ -1076,6 +1076,7 @@ class EventLoopTestsMixin:
                                                ssl=sslcontext_client,
                                                server_hostname='localhost')
         client, pr = self.loop.run_until_complete(f_c)
+        self.loop.run_until_complete(proto.connected)
 
         # close connection
         proto.transport.close()
@@ -1101,6 +1102,7 @@ class EventLoopTestsMixin:
                                           ssl=sslcontext_client,
                                           server_hostname='localhost')
         client, pr = self.loop.run_until_complete(f_c)
+        self.loop.run_until_complete(proto.connected)
 
         # extra info is available
         self.check_ssl_extra_info(client, peername=(host, port),
index 687bcb2c6ababc48ac295f466675d2ea3dd615ea..0aab4567d6ee98f580f923a8c3be977aeb1672c1 100644 (file)
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -70,6 +70,7 @@ Alexandru Ardelean
 Emmanuel Arias
 Alicia Arlen
 Jeffrey Armstrong
+Justin Turner Arthur
 Jason Asbahr
 David Ascher
 Ammar Askar