"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "ironic/tests/unit/drivers/modules/redfish/test_boot.py" between
ironic-16.0.2.tar.gz and ironic-16.0.3.tar.gz

About: OpenStack Ironic (Optional Service: Bare-Metal Provisioning) aims to provision bare metal machines instead of virtual machines, forked from the Nova baremetal driver.
The "Victoria" series (latest release).

test_boot.py  (ironic-16.0.2):test_boot.py  (ironic-16.0.3)
skipping to change at line 702 skipping to change at line 702
task, sushy.VIRTUAL_MEDIA_CD) task, sushy.VIRTUAL_MEDIA_CD)
mock__insert_vmedia.assert_called_once_with( mock__insert_vmedia.assert_called_once_with(
task, 'image-url', sushy.VIRTUAL_MEDIA_CD) task, 'image-url', sushy.VIRTUAL_MEDIA_CD)
mock_manager_utils.node_set_boot_device.assert_called_once_with( mock_manager_utils.node_set_boot_device.assert_called_once_with(
task, boot_devices.CDROM, persistent=True) task, boot_devices.CDROM, persistent=True)
mock_boot_mode_utils.sync_boot_mode.assert_called_once_with(task) mock_boot_mode_utils.sync_boot_mode.assert_called_once_with(task)
@mock.patch.object(boot_mode_utils, 'sync_boot_mode', autospec=True)
@mock.patch.object(redfish_boot, '_eject_vmedia', autospec=True) @mock.patch.object(redfish_boot, '_eject_vmedia', autospec=True)
@mock.patch.object(image_utils, 'cleanup_iso_image', autospec=True) @mock.patch.object(image_utils, 'cleanup_iso_image', autospec=True)
@mock.patch.object(redfish_boot, 'manager_utils', autospec=True) @mock.patch.object(redfish_boot, 'manager_utils', autospec=True)
def _test_prepare_instance_local_boot( def _test_prepare_instance_local_boot(
self, mock_manager_utils, self, mock_manager_utils,
mock_cleanup_iso_image, mock__eject_vmedia): mock_cleanup_iso_image, mock__eject_vmedia, mock_sync_boot_mode):
with task_manager.acquire(self.context, self.node.uuid, with task_manager.acquire(self.context, self.node.uuid,
shared=True) as task: shared=True) as task:
task.node.provision_state = states.DEPLOYING task.node.provision_state = states.DEPLOYING
task.node.driver_internal_info[ task.node.driver_internal_info[
'root_uuid_or_disk_id'] = self.node.uuid 'root_uuid_or_disk_id'] = self.node.uuid
task.driver.boot.prepare_instance(task) task.driver.boot.prepare_instance(task)
mock_manager_utils.node_set_boot_device.assert_called_once_with( mock_manager_utils.node_set_boot_device.assert_called_once_with(
task, boot_devices.DISK, persistent=True) task, boot_devices.DISK, persistent=True)
mock_cleanup_iso_image.assert_called_once_with(task) mock_cleanup_iso_image.assert_called_once_with(task)
mock__eject_vmedia.assert_called_once_with( mock__eject_vmedia.assert_called_once_with(
task, sushy.VIRTUAL_MEDIA_CD) task, sushy.VIRTUAL_MEDIA_CD)
mock_sync_boot_mode.assert_called_once_with(task)
def test_prepare_instance_local_whole_disk_image(self): def test_prepare_instance_local_whole_disk_image(self):
self.node.driver_internal_info = {'is_whole_disk_image': True} self.node.driver_internal_info = {'is_whole_disk_image': True}
self.node.save() self.node.save()
self._test_prepare_instance_local_boot() self._test_prepare_instance_local_boot()
def test_prepare_instance_local_boot_option(self): def test_prepare_instance_local_boot_option(self):
instance_info = self.node.instance_info instance_info = self.node.instance_info
instance_info['capabilities'] = '{"boot_option": "local"}' instance_info['capabilities'] = '{"boot_option": "local"}'
self.node.instance_info = instance_info self.node.instance_info = instance_info
 End of changes. 3 change blocks. 
1 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)