Skip to content

Commit 463baf4

Browse files
committed
Add a timeout to test_sslv2_fail so it passes on cygwin.
1 parent e04957d commit 463baf4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tornado/test/httpserver_test.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,12 @@ def test_sslv2_fail(self):
113113
# we've got all the other ssl version tests here.
114114
# Clients should have SSLv2 disabled by default.
115115
try:
116-
response = self.fetch('/')
116+
# The server simply closes the connection when it gets
117+
# an SSLv2 ClientHello packet.
118+
# request_timeout is needed here because on some platforms
119+
# (cygwin, but not native windows python), the close is not
120+
# detected promptly.
121+
response = self.fetch('/', request_timeout=1)
117122
except ssl.SSLError:
118123
# In some python/ssl builds the PROTOCOL_SSLv2 constant
119124
# exists but SSLv2 support is still compiled out, which

0 commit comments

Comments
 (0)