diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/hazmat/backends/test_openssl.py | 9 | ||||
-rw-r--r-- | tests/utils.py | 1 |
2 files changed, 4 insertions, 6 deletions
diff --git a/tests/hazmat/backends/test_openssl.py b/tests/hazmat/backends/test_openssl.py index 6ab16627..4c30cae2 100644 --- a/tests/hazmat/backends/test_openssl.py +++ b/tests/hazmat/backends/test_openssl.py @@ -16,9 +16,7 @@ from __future__ import absolute_import, division, print_function import pytest from cryptography import utils -from cryptography.exceptions import ( - InternalError, _Reasons -) +from cryptography.exceptions import InternalError, _Reasons from cryptography.hazmat.backends.openssl.backend import Backend, backend from cryptography.hazmat.primitives import hashes, interfaces from cryptography.hazmat.primitives.asymmetric import dsa, padding, rsa @@ -28,7 +26,6 @@ from cryptography.hazmat.primitives.ciphers.modes import CBC from ...utils import raises_unsupported_algorithm -from cryptography.utils import bit_length @utils.register_interface(interfaces.Mode) @@ -211,9 +208,9 @@ class TestOpenSSL(object): ) def test_large_key_size_on_new_openssl(self): parameters = dsa.DSAParameters.generate(2048, backend) - assert bit_length(parameters.p) == 2048 + assert utils.bit_length(parameters.p) == 2048 parameters = dsa.DSAParameters.generate(3072, backend) - assert bit_length(parameters.p) == 3072 + assert utils.bit_length(parameters.p) == 3072 class TestOpenSSLRandomEngine(object): diff --git a/tests/utils.py b/tests/utils.py index 35461821..6ee735a1 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -21,6 +21,7 @@ import pytest import six from cryptography.exceptions import UnsupportedAlgorithm + import cryptography_vectors |