Cells: Update set_admin_password for objects
Cells code was calling the compute/api set_admin_password method with an old-world style instance and failing on the task_state attribute access. This adds set_admin_password to the list of methods handled via the cells RPC redirect method which is objects compatible. Change-Id: I12e212260ed62dc9380202de31fda928a9498dcb Closes-Bug: #1335315
This commit is contained in:
@@ -798,3 +798,11 @@ class CellsManagerClassTestCase(test.NoDBTestCase):
|
||||
image_id='fake-id',
|
||||
backup_type='backup-type',
|
||||
rotation='rotation')
|
||||
|
||||
def test_set_admin_password(self):
|
||||
with mock.patch.object(self.msg_runner,
|
||||
'set_admin_password') as set_admin_password:
|
||||
self.cells_manager.set_admin_password(self.ctxt,
|
||||
instance='fake-instance', new_pass='fake-password')
|
||||
set_admin_password.assert_called_once_with(self.ctxt,
|
||||
'fake-instance', 'fake-password')
|
||||
|
||||
Reference in New Issue
Block a user