summaryrefslogtreecommitdiffstats
path: root/Lib/test/support
diff options
context:
space:
mode:
authorBerker Peksag <berker.peksag@gmail.com>2015-03-02 04:01:01 (GMT)
committerBerker Peksag <berker.peksag@gmail.com>2015-03-02 04:01:01 (GMT)
commitbcdfc6a1fa9eabb06b886a82218ebae3384784d0 (patch)
tree3e9214d0a08bc0d81ac12a1233dc582b341b45bc /Lib/test/support
parent6e820c0548671847d873f6550ed9e5e7eaaaef89 (diff)
downloadcpython-bcdfc6a1fa9eabb06b886a82218ebae3384784d0.zip
cpython-bcdfc6a1fa9eabb06b886a82218ebae3384784d0.tar.gz
cpython-bcdfc6a1fa9eabb06b886a82218ebae3384784d0.tar.bz2
Issue #23387: Skip test_issue16464 if it raises an 5xx error.
Also, remove support.run_doctest() since there is no doctests in test_urllib2 and urllib.request.
Diffstat (limited to 'Lib/test/support')
-rw-r--r--Lib/test/support/__init__.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/support/__init__.py b/Lib/test/support/__init__.py
index d98068c..32b5687 100644
--- a/Lib/test/support/__init__.py
+++ b/Lib/test/support/__init__.py
@@ -1324,6 +1324,8 @@ def transient_internet(resource_name, *, timeout=30.0, errnos=()):
n = getattr(err, 'errno', None)
if (isinstance(err, socket.timeout) or
(isinstance(err, socket.gaierror) and n in gai_errnos) or
+ (isinstance(err, urllib.error.HTTPError) and
+ 500 <= err.code <= 599) or
(isinstance(err, urllib.error.URLError) and
"ConnectionRefusedError" in err.reason) or
n in captured_errnos):