Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Lib/test/test_asyncio/test_sslproto.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,7 @@ async def client(addr):

def test_start_tls_server_1(self):
HELLO_MSG = b'1' * 1024 * 1024
TIMEOUT = 60 # seconds

server_context = test_utils.simple_server_sslcontext()
client_context = test_utils.simple_client_sslcontext()
Expand All @@ -256,7 +257,7 @@ def test_start_tls_server_1(self):

def client(sock, addr):
time.sleep(0.5)
sock.settimeout(5)
sock.settimeout(TIMEOUT)

sock.connect(addr)
data = sock.recv_all(len(HELLO_MSG))
Expand Down Expand Up @@ -309,7 +310,7 @@ async def main():

with self.tcp_client(lambda sock: client(sock, addr)):
self.loop.run_until_complete(
asyncio.wait_for(main(), loop=self.loop, timeout=10))
asyncio.wait_for(main(), loop=self.loop, timeout=TIMEOUT * 2))

def test_start_tls_wrong_args(self):
async def main():
Expand All @@ -332,7 +333,6 @@ def new_loop(self):

@unittest.skipIf(ssl is None, 'No ssl module')
@unittest.skipUnless(hasattr(asyncio, 'ProactorEventLoop'), 'Windows only')
@unittest.skipIf(os.environ.get('APPVEYOR'), 'XXX: issue 32458')
class ProactorStartTLSTests(BaseStartTLS, unittest.TestCase):

def new_loop(self):
Expand Down