Use NoDBTestCase for powervm driver tests

TestCase is being replaced by NoDBTestCase for the powervm driver test
code. This will prevent running the database schema migrations
unnecessarily and will let the developer know if the tests touch the
DB when the test case is claiming that it shouldn't.

Change-Id: I2b04b785c71c6f2cc825215e2773a00e85a67a89
This commit is contained in:
esberglu 2017-11-15 09:52:05 -06:00
parent 008bc4065d
commit c352901ce4
3 changed files with 3 additions and 3 deletions

View File

@ -35,7 +35,7 @@ FAKE_INST_UUID = uuidutils.generate_uuid(dashed=True)
FAKE_INST_UUID_PVM = vm.get_pvm_uuid(mock.Mock(uuid=FAKE_INST_UUID))
class TestSSPDiskAdapter(test.TestCase):
class TestSSPDiskAdapter(test.NoDBTestCase):
"""Unit Tests for the LocalDisk storage driver."""
def setUp(self):

View File

@ -19,7 +19,7 @@ from nova import test
from nova.virt.powervm.tasks import storage as tf_stg
class TestStorage(test.TestCase):
class TestStorage(test.NoDBTestCase):
def setUp(self):
super(TestStorage, self).setUp()

View File

@ -22,7 +22,7 @@ from nova import test
from nova.virt.powervm.tasks import vm as tf_vm
class TestVMTasks(test.TestCase):
class TestVMTasks(test.NoDBTestCase):
def setUp(self):
super(TestVMTasks, self).setUp()
self.apt = mock.Mock()