mirror of
https://github.com/saymrwulf/cryptography.git
synced 2026-05-14 20:37:55 +00:00
Pain the bikeshed a different colour
This commit is contained in:
parent
a2aacf7274
commit
85a791f0fa
2 changed files with 2 additions and 3 deletions
|
|
@ -1624,7 +1624,7 @@ def test_raises_unsupported_algorithm_wrong_type():
|
|||
|
||||
def test_raises_unsupported_algorithm_wrong_reason():
|
||||
# Check that it fails if the wrong reason code is raised.
|
||||
with pytest.raises(pytest.fail.Exception):
|
||||
with pytest.raises(AssertionError):
|
||||
with raises_unsupported_algorithm(None):
|
||||
raise UnsupportedAlgorithm("An error.",
|
||||
_Reasons.BACKEND_MISSING_INTERFACE)
|
||||
|
|
|
|||
|
|
@ -74,8 +74,7 @@ def raises_unsupported_algorithm(reason):
|
|||
with pytest.raises(UnsupportedAlgorithm) as exc_info:
|
||||
yield exc_info
|
||||
|
||||
if exc_info.value._reason is not reason:
|
||||
pytest.fail("Did not get expected reason tag for UnsupportedAlgorithm")
|
||||
assert exc_info.value._reason is reason
|
||||
|
||||
|
||||
def load_vectors_from_file(filename, loader):
|
||||
|
|
|
|||
Loading…
Reference in a new issue