[Python-checkins] Fix tests if Python compiled without SSL (#5367)

Andrew Svetlov webhook-mailer at python.org
Sat Jan 27 17:00:40 EST 2018


https://github.com/python/cpython/commit/0f54e00e9633638a8da7f35b2f65556396eedfd0
commit: 0f54e00e9633638a8da7f35b2f65556396eedfd0
branch: master
author: Andrew Svetlov <andrew.svetlov at gmail.com>
committer: GitHub <noreply at github.com>
date: 2018-01-28T00:00:37+02:00
summary:

Fix tests if Python compiled without SSL (#5367)

files:
M Lib/test/test_asyncio/test_events.py

diff --git a/Lib/test/test_asyncio/test_events.py b/Lib/test/test_asyncio/test_events.py
index b66d91d415e8..f54802cf8af2 100644
--- a/Lib/test/test_asyncio/test_events.py
+++ b/Lib/test/test_asyncio/test_events.py
@@ -2134,6 +2134,8 @@ def prepare(self, *, is_ssl=False, close_after=0):
         port = support.find_unused_port()
         srv_proto = MySendfileProto(loop=self.loop, close_after=close_after)
         if is_ssl:
+            if not ssl:
+                self.skipTest("No ssl module")
             srv_ctx = test_utils.simple_server_sslcontext()
             cli_ctx = test_utils.simple_client_sslcontext()
         else:



More information about the Python-checkins mailing list