bpo-37583: Add err 113 to support.get_socket_conn_refused_errs() (GH-15259)

Add error number 113 EHOSTUNREACH to get_socket_conn_refused_errs()
of test.support.
This commit is contained in:
Hai Shi 2019-08-14 04:52:36 -05:00 committed by Victor Stinner
parent 37fd9f73e2
commit fbb0c032e8
1 changed files with 3 additions and 0 deletions

View File

@ -1423,6 +1423,9 @@ def get_socket_conn_refused_errs():
# bpo-31910: socket.create_connection() fails randomly # bpo-31910: socket.create_connection() fails randomly
# with EADDRNOTAVAIL on Travis CI # with EADDRNOTAVAIL on Travis CI
errors.append(errno.EADDRNOTAVAIL) errors.append(errno.EADDRNOTAVAIL)
if hasattr(errno, 'EHOSTUNREACH'):
# bpo-37583: The destination host cannot be reached
errors.append(errno.EHOSTUNREACH)
return errors return errors