]> granicus.if.org Git - python/commitdiff
Errors in "client" methods in test_socket were ignored because of a bogus except...
authorAntoine Pitrou <solipsis@pitrou.net>
Sat, 23 Jun 2012 23:34:13 +0000 (01:34 +0200)
committerAntoine Pitrou <solipsis@pitrou.net>
Sat, 23 Jun 2012 23:34:13 +0000 (01:34 +0200)
(this could reveal test failures!)

Lib/test/test_socket.py

index 092e94f38034b83bc764fd7fd2b9977b749bf7a1..8520401b4df35408c5bd3214a7d945a06e52493e 100644 (file)
@@ -2,6 +2,7 @@
 
 import unittest
 from test import support
+from unittest.case import _ExpectedFailure
 
 import errno
 import io
@@ -241,7 +242,7 @@ class ThreadableTest:
             raise TypeError("test_func must be a callable function")
         try:
             test_func()
-        except unittest._ExpectedFailure:
+        except _ExpectedFailure:
             # We deliberately ignore expected failures
             pass
         except BaseException as e: