From 37dee20d2f963ca08e56a95be8c654e1920e4a2a Mon Sep 17 00:00:00 2001 From: Rick Harris Date: Tue, 31 Jul 2012 18:23:14 +0000 Subject: Compute: Error out instance on rebuild and resize. If a rebuild or a resize fails, then we should error out the instance. This code takes an idiom we already use in the compute manager and adds it to the rebuild and resize code. Change-Id: Ia90c038eb4677e109d58e9b79bb8a05490689c9f --- nova/tests/compute/test_compute.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'nova/tests') diff --git a/nova/tests/compute/test_compute.py b/nova/tests/compute/test_compute.py index 4aa6545d1..46f06e7b3 100644 --- a/nova/tests/compute/test_compute.py +++ b/nova/tests/compute/test_compute.py @@ -1150,9 +1150,10 @@ class ComputeTestCase(BaseTestCase): instance = db.instance_get_by_uuid(self.context, inst_ref['uuid']) - self.compute._rebuild_instance(self.context.elevated(), - jsonutils.to_primitive(instance), - image_ref, new_image_ref, dict(new_pass=password)) + self.compute.rebuild_instance(self.context.elevated(), + image_ref, new_image_ref, + instance=jsonutils.to_primitive(instance), + new_pass=password) instance = db.instance_get_by_uuid(self.context, inst_ref['uuid']) -- cgit