Fix test_alpn_protocols from test_ssl

This commit is contained in:
Charalampos Stratakis 2017-06-26 11:55:09 +02:00
parent 9dab8a4c1f
commit f83409d8b6
2 changed files with 27 additions and 1 deletions

View File

@ -0,0 +1,16 @@
diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
index d203cdd..c128dae 100644
--- a/Lib/test/test_ssl.py
+++ b/Lib/test/test_ssl.py
@@ -3256,8 +3256,9 @@ if _have_threads:
except ssl.SSLError as e:
stats = e
- if expected is None and IS_OPENSSL_1_1:
- # OpenSSL 1.1.0 raises handshake error
+ if (expected is None and IS_OPENSSL_1_1
+ and ssl.OPENSSL_VERSION_INFO < (1, 1, 0, 6)):
+ # OpenSSL 1.1.0 to 1.1.0e raises handshake error
self.assertIsInstance(stats, ssl.SSLError)
else:
msg = "failed trying %s (s) and %s (c).\n" \

View File

@ -98,7 +98,7 @@
Summary: Version 3.5 of the Python programming language
Name: python%{pyshortver}
Version: %{pybasever}.3
Release: 1%{?dist}
Release: 2%{?dist}
License: Python
Group: Development/Languages
@ -394,6 +394,12 @@ Patch267: 00267-install-pip-in-a-venv-with-system-site-packages.patch
# Fixed upstream: http://bugs.python.org/issue29243
Patch269: 00269-fix-multiple-compilations-issue-with-pgo-builds.patch
# 00270 #
# Fix test_alpn_protocols from test_ssl as openssl > 1.1.0f
# changed the behaviour of the ALPN hook.
# Fixed upstream: http://bugs.python.org/issue30714
Patch270: 00270-fix-ssl-alpn-hook-test.patch
# (New patches go here ^^^)
#
# When adding new patches to "python" and "python3" in Fedora, EL, etc.,
@ -509,6 +515,7 @@ rm -r Modules/zlib || exit 1
%patch259 -p1
%patch267 -p1
%patch269 -p1
%patch270 -p1
# Currently (2010-01-15), http://docs.python.org/library is for 2.6, and there
# are many differences between 2.6 and the Python 3 library.
@ -1039,6 +1046,9 @@ CheckPython optimized
# ======================================================
%changelog
* Mon Jun 26 2017 Charalampos Stratakis <cstratak@redhat.com> - 3.5.3-2
- Fix test_alpn_protocols from test_ssl
* Thu May 11 2017 Charalampos Stratakis <cstratak@redhat.com> - 3.5.3-1
- Rebased to version 3.5.3 from F25
- Enable profile guided optimizations for x86_64 and i686 architectures