mirror of
https://github.com/openkmip/pykmip
synced 2025-12-23 19:53:24 +00:00
Remove unused error code
This change removes unused exceptions defined in core/errors.py, along with the errors.py module itself. The few used items from this file are migrated over to core/exceptions.py. Any dependent code is updated, dropping the use of errors.py and adding in the use of exceptions.py.
This commit is contained in:
@@ -15,8 +15,7 @@
|
||||
|
||||
from testtools import TestCase
|
||||
|
||||
from kmip.core.errors import ErrorStrings
|
||||
|
||||
from kmip.core import exceptions
|
||||
from kmip.core import utils
|
||||
|
||||
|
||||
@@ -62,12 +61,24 @@ class TestBytearrayStream(TestCase):
|
||||
super(TestBytearrayStream, self).setUp()
|
||||
self.stream = utils.BytearrayStream()
|
||||
|
||||
self.bad_type = ErrorStrings.BAD_EXP_RECV.format('BytearrayStream.{0}',
|
||||
'type', '{1}', '{2}')
|
||||
self.bad_len = ErrorStrings.BAD_EXP_RECV.format('BytearrayStream.{0}',
|
||||
'length', '{1}', '{2}')
|
||||
self.bad_val = ErrorStrings.BAD_EXP_RECV.format('BytearrayStream.{0}',
|
||||
'value', '{1}', '{2}')
|
||||
self.bad_type = exceptions.ErrorStrings.BAD_EXP_RECV.format(
|
||||
'BytearrayStream.{0}',
|
||||
'type',
|
||||
'{1}',
|
||||
'{2}'
|
||||
)
|
||||
self.bad_len = exceptions.ErrorStrings.BAD_EXP_RECV.format(
|
||||
'BytearrayStream.{0}',
|
||||
'length',
|
||||
'{1}',
|
||||
'{2}'
|
||||
)
|
||||
self.bad_val = exceptions.ErrorStrings.BAD_EXP_RECV.format(
|
||||
'BytearrayStream.{0}',
|
||||
'value',
|
||||
'{1}',
|
||||
'{2}'
|
||||
)
|
||||
|
||||
def tearDown(self):
|
||||
super(TestBytearrayStream, self).tearDown()
|
||||
|
||||
Reference in New Issue
Block a user