diff options
author | Alex Gaynor <alex.gaynor@gmail.com> | 2014-03-22 15:09:34 -0700 |
---|---|---|
committer | Alex Stapleton <alexs@prol.etari.at> | 2014-03-27 07:31:12 +0000 |
commit | 7a489dbd116edd4ca5a6104b74748f3a4f712d15 (patch) | |
tree | 03b1fc8cdcde0e7c1032495d7d3b947540b931ad /tests/hazmat/primitives/test_hashes.py | |
parent | 844c14a15884fb60871640576e30a61e6c4c2db1 (diff) | |
download | cryptography-7a489dbd116edd4ca5a6104b74748f3a4f712d15.tar.gz cryptography-7a489dbd116edd4ca5a6104b74748f3a4f712d15.tar.bz2 cryptography-7a489dbd116edd4ca5a6104b74748f3a4f712d15.zip |
Fixed #809 -- switch back to always using UnsupportedAlgorithm
Diffstat (limited to 'tests/hazmat/primitives/test_hashes.py')
-rw-r--r-- | tests/hazmat/primitives/test_hashes.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/tests/hazmat/primitives/test_hashes.py b/tests/hazmat/primitives/test_hashes.py index 5b318f64..ce8e92a3 100644 --- a/tests/hazmat/primitives/test_hashes.py +++ b/tests/hazmat/primitives/test_hashes.py @@ -20,9 +20,7 @@ import pytest import six from cryptography import utils -from cryptography.exceptions import ( - AlreadyFinalized, UnsupportedHash, UnsupportedInterface -) +from cryptography.exceptions import AlreadyFinalized, UnsupportedAlgorithm from cryptography.hazmat.backends.interfaces import HashBackend from cryptography.hazmat.primitives import hashes, interfaces @@ -72,7 +70,7 @@ class TestHashContext(object): h.finalize() def test_unsupported_hash(self, backend): - with pytest.raises(UnsupportedHash): + with pytest.raises(UnsupportedAlgorithm): hashes.Hash(UnsupportedDummyHash(), backend) @@ -183,5 +181,5 @@ class TestMD5(object): def test_invalid_backend(): pretend_backend = object() - with pytest.raises(UnsupportedInterface): + with pytest.raises(UnsupportedAlgorithm): hashes.Hash(hashes.SHA1(), pretend_backend) |