aboutsummaryrefslogtreecommitdiffstats
path: root/tests/hazmat/bindings
diff options
context:
space:
mode:
Diffstat (limited to 'tests/hazmat/bindings')
-rw-r--r--tests/hazmat/bindings/test_openssl.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/hazmat/bindings/test_openssl.py b/tests/hazmat/bindings/test_openssl.py
index f317f07f..fb1e62fa 100644
--- a/tests/hazmat/bindings/test_openssl.py
+++ b/tests/hazmat/bindings/test_openssl.py
@@ -21,12 +21,15 @@ class TestOpenSSL(object):
def test_crypto_lock_init(self):
b = Binding()
- if b.lib.CRYPTOGRAPHY_OPENSSL_110_OR_GREATER:
- pytest.skip("Requires an older OpenSSL. Must be < 1.1.0")
b.init_static_locks()
lock_cb = b.lib.CRYPTO_get_locking_callback()
- assert lock_cb != b.ffi.NULL
+ if b.lib.CRYPTOGRAPHY_OPENSSL_110_OR_GREATER:
+ assert lock_cb == b.ffi.NULL
+ assert b.lib.Cryptography_HAS_LOCKING_CALLBACKS == 0
+ else:
+ assert lock_cb != b.ffi.NULL
+ assert b.lib.Cryptography_HAS_LOCKING_CALLBACKS == 1
def test_add_engine_more_than_once(self):
b = Binding()