From 12597e5e6200ee073a862b4bf1addb1e2b79e884 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Fri, 12 Apr 2024 16:15:32 +0200 Subject: [PATCH] gh-115627: Fix ssl test_pha_required_nocert() Accept also BrokenPipeError error message. --- Lib/test/test_ssl.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py index 0e50d09c8f28d6..6ec010d13f9e7e 100644 --- a/Lib/test/test_ssl.py +++ b/Lib/test/test_ssl.py @@ -4537,7 +4537,11 @@ def msg_cb(conn, direction, version, content_type, msg_type, data): # server aborts connection with an error. with self.assertRaisesRegex( OSError, - 'certificate required|EOF occurred|closed by the remote host|Connection reset by peer' + ('certificate required' + '|EOF occurred' + '|closed by the remote host' + '|Connection reset by peer' + '|Broken pipe') ): # receive CertificateRequest data = s.recv(1024)