Do not use nova.test in placement.test_fault_wrap
The tests are very straightforward and do not require any of the setup and fixtures that nova.test.NoDBTestCase supplies. Also, in the future of placement extraction we don't want the dependecy. By not using NoDBTestCase we lose a fixture that captures stderr output, produced when the exception used by the tests is (intentionally) raised. This adds slightly to the volume of output in test logs but is light enough to not yet be a concern and adds some useful visibility. We can explore adding such capturing back, as we create fixtures specific to placement. Partially implements blueprint placement-extract Change-Id: Iba3455a7858badb34d4224429acb69273e6a88c4
This commit is contained in:
parent
01b9bc742d
commit
5787ab46d4
@ -15,10 +15,10 @@
|
||||
import mock
|
||||
|
||||
from oslo_serialization import jsonutils
|
||||
import testtools
|
||||
import webob
|
||||
|
||||
from nova.api.openstack.placement import fault_wrap
|
||||
from nova import test
|
||||
|
||||
|
||||
ERROR_MESSAGE = 'that was not supposed to happen'
|
||||
@ -28,7 +28,7 @@ class Fault(Exception):
|
||||
pass
|
||||
|
||||
|
||||
class TestFaultWrapper(test.NoDBTestCase):
|
||||
class TestFaultWrapper(testtools.TestCase):
|
||||
|
||||
@staticmethod
|
||||
@webob.dec.wsgify
|
||||
|
Loading…
Reference in New Issue
Block a user