mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
bpo-38912: fix close before connect callback in test_asyncio SSL tests (GH-22691)
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.
This commit is contained in:
parent
23c0fb8edd
commit
de73d432bb
2 changed files with 3 additions and 0 deletions
|
@ -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),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue