diff options
| author | Alex Gaynor <alex.gaynor@gmail.com> | 2015-09-26 17:46:22 -0400 | 
|---|---|---|
| committer | Alex Gaynor <alex.gaynor@gmail.com> | 2015-09-26 17:46:22 -0400 | 
| commit | 95063f861bdc1e02bb1fbed966b44c25a9fe4533 (patch) | |
| tree | 13f8357bda8949d130defefc75025ac886d12fb9 /tests/hazmat/backends | |
| parent | 6efcd60f319920e5b4eae971c1ddf704e56d866d (diff) | |
| download | cryptography-95063f861bdc1e02bb1fbed966b44c25a9fe4533.tar.gz cryptography-95063f861bdc1e02bb1fbed966b44c25a9fe4533.tar.bz2 cryptography-95063f861bdc1e02bb1fbed966b44c25a9fe4533.zip  | |
Use InternalError for stuff
Diffstat (limited to 'tests/hazmat/backends')
| -rw-r--r-- | tests/hazmat/backends/test_openssl.py | 20 | 
1 files changed, 1 insertions, 19 deletions
diff --git a/tests/hazmat/backends/test_openssl.py b/tests/hazmat/backends/test_openssl.py index abd707ca..8fd0d711 100644 --- a/tests/hazmat/backends/test_openssl.py +++ b/tests/hazmat/backends/test_openssl.py @@ -20,7 +20,6 @@ from cryptography.hazmat.backends.openssl.backend import (      Backend, backend  )  from cryptography.hazmat.backends.openssl.ec import _sn_to_elliptic_curve -from cryptography.hazmat.bindings.openssl.binding import UnhandledOpenSSLError  from cryptography.hazmat.primitives import hashes, serialization  from cryptography.hazmat.primitives.asymmetric import dsa, ec, padding  from cryptography.hazmat.primitives.ciphers import ( @@ -125,7 +124,7 @@ class TestOpenSSL(object):      def test_openssl_assert(self):          backend.openssl_assert(True) -        with pytest.raises(UnhandledOpenSSLError): +        with pytest.raises(InternalError):              backend.openssl_assert(False)      def test_consume_errors(self): @@ -140,23 +139,6 @@ class TestOpenSSL(object):          assert backend._lib.ERR_peek_error() == 0          assert len(errors) == 10 -    def test_openssl_error_string(self): -        backend._lib.ERR_put_error( -            backend._lib.ERR_LIB_EVP, -            backend._lib.EVP_F_EVP_DECRYPTFINAL_EX, -            0, -            b"test_openssl.py", -            -1 -        ) - -        errors = backend._consume_errors() -        exc = backend._unknown_error(errors[0]) - -        assert ( -            "digital envelope routines:" -            "EVP_DecryptFinal_ex:digital envelope routines" in str(exc) -        ) -      def test_ssl_ciphers_registered(self):          meth = backend._lib.TLSv1_method()          ctx = backend._lib.SSL_CTX_new(meth)  | 
