diff options
author | Ayrx <terrycwk1994@gmail.com> | 2014-04-22 19:31:26 +0800 |
---|---|---|
committer | Ayrx <terrycwk1994@gmail.com> | 2014-04-22 23:32:52 +0800 |
commit | bafbc3385e4fb3c048b3daa61ff2807a88f5b2e1 (patch) | |
tree | 4191c628d1657122f1b1406b3dd8817f0cd79e87 /tests/hazmat | |
parent | 771fc77eb3f3e0d43471c6bde39a194bb17affbb (diff) | |
download | cryptography-bafbc3385e4fb3c048b3daa61ff2807a88f5b2e1.tar.gz cryptography-bafbc3385e4fb3c048b3daa61ff2807a88f5b2e1.tar.bz2 cryptography-bafbc3385e4fb3c048b3daa61ff2807a88f5b2e1.zip |
Added _REASON
Diffstat (limited to 'tests/hazmat')
-rw-r--r-- | tests/hazmat/backends/test_multibackend.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/hazmat/backends/test_multibackend.py b/tests/hazmat/backends/test_multibackend.py index 2fa9f758..d8c09bd7 100644 --- a/tests/hazmat/backends/test_multibackend.py +++ b/tests/hazmat/backends/test_multibackend.py @@ -13,8 +13,6 @@ from __future__ import absolute_import, division, print_function -import pytest - from cryptography import utils from cryptography.exceptions import ( UnsupportedAlgorithm, _Reasons @@ -120,7 +118,7 @@ class DummyCMACBackend(object): def create_cmac_ctx(self, algorithm): if not self.cmac_algorithm_supported(algorithm): - raise UnsupportedAlgorithm("") + raise UnsupportedAlgorithm("", _Reasons.UNSUPPORTED_CIPHER) class TestMultiBackend(object): @@ -252,5 +250,5 @@ class TestMultiBackend(object): cmac.CMAC(algorithms.AES(fake_key), backend) - with pytest.raises(UnsupportedAlgorithm): + with raises_unsupported_algorithm(_Reasons.UNSUPPORTED_CIPHER): cmac.CMAC(algorithms.TripleDES(fake_key), backend) |