From d509af540d080c01128404b315dfdf785f1c9737 Mon Sep 17 00:00:00 2001 From: Felix Fontein Date: Sun, 21 Jul 2024 12:11:34 +0200 Subject: [PATCH] Disable unit tests that fail with cryptography 43.0.0. (#786) --- .../plugins/module_utils/crypto/test_cryptography_support.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/unit/plugins/module_utils/crypto/test_cryptography_support.py b/tests/unit/plugins/module_utils/crypto/test_cryptography_support.py index 23564c3d8..b15251610 100644 --- a/tests/unit/plugins/module_utils/crypto/test_cryptography_support.py +++ b/tests/unit/plugins/module_utils/crypto/test_cryptography_support.py @@ -130,7 +130,8 @@ def test_parse_dn_component(name, options, expected): # Cryptography < 2.9 does not allow empty strings # (https://github.com/pyca/cryptography/commit/87b2749c52e688c809f1861e55d958c64147493c) -if LooseVersion(cryptography.__version__) >= LooseVersion('2.9'): +# Cryptoraphy 43.0.0+ also doesn't allow this anymore +if LooseVersion('2.9') <= LooseVersion(cryptography.__version__) < LooseVersion('43.0.0'): @pytest.mark.parametrize('name, options, expected', [ (b'CN=', {}, (NameAttribute(oid.NameOID.COMMON_NAME, u''), b'')), (b'CN= ', {}, (NameAttribute(oid.NameOID.COMMON_NAME, u''), b'')),