Merge "Require more specific exception"
This commit is contained in:
commit
bc2b5326fa
@ -3877,9 +3877,7 @@ class TestImagesController(base.IsolatedUnitTest):
|
|||||||
virtual_size=3072, extra_properties=props)
|
virtual_size=3072, extra_properties=props)
|
||||||
self.controller._delete_encryption_key(request.context, image)
|
self.controller._delete_encryption_key(request.context, image)
|
||||||
# Make sure the encryption key is gone
|
# Make sure the encryption key is gone
|
||||||
# TODO(tkajinam): Replace Exception by ManagedObjectNotFoundError once
|
self.assertRaises(castellan_exception.ManagedObjectNotFoundError,
|
||||||
# castellan in u-c is bumped to 4.4.0
|
|
||||||
self.assertRaises(Exception, # noqa
|
|
||||||
self.controller._key_manager.get,
|
self.controller._key_manager.get,
|
||||||
request.context, fake_encryption_key)
|
request.context, fake_encryption_key)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user