Discussion:
[Python-3000-checkins] r65072 - python/branches/py3k/Lib/test/test_ssl.py
bill.janssen
2008-07-17 18:17:20 UTC
Permalink
Author: bill.janssen
Date: Thu Jul 17 20:17:20 2008
New Revision: 65072

Log:
catch socket.error errors in badCertTest

Modified:
python/branches/py3k/Lib/test/test_ssl.py

Modified: python/branches/py3k/Lib/test/test_ssl.py
==============================================================================
--- python/branches/py3k/Lib/test/test_ssl.py (original)
+++ python/branches/py3k/Lib/test/test_ssl.py Thu Jul 17 20:17:20 2008
@@ -601,6 +601,9 @@
except ssl.SSLError as x:
if support.verbose:
sys.stdout.write("\nSSLError is %s\n" % x)
+ except socket.error as x:
+ if support.verbose:
+ sys.stdout.write("\nsocket.error is %s\n" % x)
else:
raise support.TestFailed(
"Use of invalid cert should have failed!")

Loading...