diff --git a/irctest/client_mock.py b/irctest/client_mock.py index 2848e3d..d85b1bc 100644 --- a/irctest/client_mock.py +++ b/irctest/client_mock.py @@ -1,4 +1,5 @@ import ssl +import sys import time import socket from .irc_utils import message_parser @@ -104,7 +105,7 @@ class ClientMock: ret = self.conn.sendall(encoded_line) except BrokenPipeError: raise ConnectionClosed() - if self.ssl: # https://bugs.python.org/issue25951 + if sys.version_info <= (3, 6) and self.ssl: # https://bugs.python.org/issue25951 assert ret == len(encoded_line), (ret, repr(encoded_line)) else: assert ret is None, ret