From 3e3444fa96a3fa911e99e1c12f1a0d859563ce2c Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Mon, 11 Jul 2016 17:03:13 -0400 Subject: Use a series of constants for OpenSSL version checks (#3037) * Use a series of constants for OpenSSL version checks. N.B. I removed several qualifiers that were being used to express beta vs. release in OpenSSL version numbers. Reviewers please look closely! * Convert some python as well, also add the file * flake8 * Simplify code, remove functionality that can be expressed more simply * clean up the tests as well * more constants * wrap long lines * reflect feedback * unused * add this back? --- tests/hazmat/bindings/test_openssl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/hazmat/bindings') diff --git a/tests/hazmat/bindings/test_openssl.py b/tests/hazmat/bindings/test_openssl.py index 41c653b9..f41bcf35 100644 --- a/tests/hazmat/bindings/test_openssl.py +++ b/tests/hazmat/bindings/test_openssl.py @@ -138,7 +138,7 @@ class TestOpenSSL(object): def test_conditional_removal(self): b = Binding() - if b.lib.OPENSSL_VERSION_NUMBER >= 0x10001000: + if b.lib.CRYPTOGRAPHY_OPENSSL_101_OR_GREATER: assert b.lib.CMAC_Init else: with pytest.raises(AttributeError): -- cgit v1.2.3