diff options
author | Victor Stinner <vstinner@python.org> | 2023-08-23 21:57:11 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-23 21:57:11 (GMT) |
commit | 592bacb6fc0833336c0453e818e9b95016e9fd47 (patch) | |
tree | 43d494b8ce891c11c6d2145b733fde167d778364 /Lib/test/test_multiprocessing_spawn/test_processes.py | |
parent | ec3527d19627e62212f792513e6cab62b6f0f46a (diff) | |
download | cpython-592bacb6fc0833336c0453e818e9b95016e9fd47.zip cpython-592bacb6fc0833336c0453e818e9b95016e9fd47.tar.gz cpython-592bacb6fc0833336c0453e818e9b95016e9fd47.tar.bz2 |
gh-108342: Make ssl TestPreHandshakeClose more reliable (#108370)
* In preauth tests of test_ssl, explicitly break reference cycles
invoving SingleConnectionTestServerThread to make sure that the
thread is deleted. Otherwise, the test marks the environment as
altered because the threading module sees a "dangling thread"
(SingleConnectionTestServerThread). This test leak was introduced
by the test added for the fix of issue gh-108310.
* Use support.SHORT_TIMEOUT instead of hardcoded 1.0 or 2.0 seconds
timeout.
* SingleConnectionTestServerThread.run() catchs TimeoutError
* Fix a race condition (missing synchronization) in
test_preauth_data_to_tls_client(): the server now waits until the
client connect() completed in call_after_accept().
* test_https_client_non_tls_response_ignored() calls server.join()
explicitly.
* Replace "localhost" with server.listener.getsockname()[0].
Diffstat (limited to 'Lib/test/test_multiprocessing_spawn/test_processes.py')
0 files changed, 0 insertions, 0 deletions