Fixes HyperV compute "resume" tests

Fixes Bug #1083018

Adds support for the extra parameter added in the compute driver's
resume method. The added network_info parameter is currently not used
and can safely be set to None.

Change-Id: I887d48f39601323433384833f8b8d33132858b59
This commit is contained in:
Alessandro Pilotti
2012-11-29 00:40:17 +02:00
parent eed899e556
commit 20c219ff76

View File

@@ -275,19 +275,13 @@ class HyperVAPITestCase(basetestcase.BaseTestCase):
constants.HYPERV_VM_STATE_SUSPENDED,
constants.HYPERV_VM_STATE_SUSPENDED)
# NOTE (rmk): Resume now takes 3 mandatory args. These tests need to
# be updated but cannot be without involvement from the maintainers
# of the HyperV driver/tests.
def test_resume(self):
self.skipTest("Requires updating.")
self._test_vm_state_change(self._conn.resume,
self._test_vm_state_change(lambda i: self._conn.resume(i, None),
constants.HYPERV_VM_STATE_SUSPENDED,
constants.HYPERV_VM_STATE_ENABLED)
# NOTE: (rmk): See comment for test_resume().
def test_resume_already_running(self):
self.skipTest("Requires updating.")
self._test_vm_state_change(self._conn.resume, None,
self._test_vm_state_change(lambda i: self._conn.resume(i, None), None,
constants.HYPERV_VM_STATE_ENABLED)
def test_power_off(self):