summaryrefslogtreecommitdiff
path: root/nova/tests/unit/test_notifications.py
diff options
context:
space:
mode:
authorTakashi NATSUME <natsume.takashi@lab.ntt.co.jp>2019-03-22 12:44:45 +0900
committerTakashi NATSUME <natsume.takashi@lab.ntt.co.jp>2019-04-30 13:01:40 +0000
commit7cf16e317bab6e2520b3ee5241a5ed73c17749a4 (patch)
tree2e37695781582c0c1caf76994560b595bf87a868 /nova/tests/unit/test_notifications.py
parentce5ef763b58cad09440e0da67733ce578068752a (diff)
downloadnova-7cf16e317bab6e2520b3ee5241a5ed73c17749a4.tar.gz
Remove deprecated 'default_flavor' config option
The deprecated 'default_flavor' option has been removed. The following methods in nova/compute/flavors.py have been removed because they are only used in unit tests. * get_default_flavor * get_flavor_by_name Change-Id: If1e461da382f707be2b5ba89f74f77269f0909dd
Diffstat (limited to 'nova/tests/unit/test_notifications.py')
-rw-r--r--nova/tests/unit/test_notifications.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/nova/tests/unit/test_notifications.py b/nova/tests/unit/test_notifications.py
index aa058ade7c..ea80910f27 100644
--- a/nova/tests/unit/test_notifications.py
+++ b/nova/tests/unit/test_notifications.py
@@ -24,7 +24,6 @@ from oslo_context import fixture as o_fixture
from oslo_utils.fixture import uuidsentinel as uuids
from oslo_utils import timeutils
-from nova.compute import flavors
from nova.compute import task_states
from nova.compute import vm_states
from nova import context
@@ -77,7 +76,7 @@ class NotificationsTestCase(test.TestCase):
self.decorated_function_called = False
def _wrapped_create(self, params=None):
- instance_type = flavors.get_flavor_by_name('m1.tiny')
+ instance_type = objects.Flavor.get_by_name(self.context, 'm1.tiny')
inst = objects.Instance(image_ref=uuids.image_ref,
user_id=self.user_id,
project_id=self.project_id,