nova/nova/tests/unit/virt
Alexandre Arents 9f9f8d330a Do not update root_device_name during guest config
_get_guest_config() is currently updating instance.root_device_name
and called in many ways like:

_hard_reboot(), rescue(), spawn(), resume(), finish_migration(),
finish_revert_migration()

It is an issue because root_device_name is initally set during instance
build and should remain the same after:

manager.py: _do_build_and_run_instance()
             ..
               _default_block_device_names() <-here
               ..
               driver.spawn()

This may lead to edge case, like in rescue where this value can be mistakenly
updated to reflect disk bus property of rescue image (hw_disk_bus).
Further more, a _get* method should not modify instance object.

Note that test test_get_guest_config_bug_1118829 is removed because no more
relevant with current code.

Change-Id: I1787f9717618d0837208844e8065840d30341cf7
Closes-Bug: #1835926
(cherry picked from commit 5e0ed5e7fe)
(cherry picked from commit 5e858d0cbd)
2019-12-06 20:27:12 +00:00
..
disk lxc: make use of filter python3 compatible 2019-08-14 19:21:52 +00:00
hyperv Fix 'has_calls' method calls in unit tests 2019-08-20 11:16:37 +09:00
image
ironic Merge "Fix rebuild of baremetal instance when vm_state is ERROR" into stable/stein 2019-09-18 17:31:19 +00:00
libvirt Do not update root_device_name during guest config 2019-12-06 20:27:12 +00:00
powervm Merge "Share snapshot image membership with instance owner" 2019-03-12 18:43:12 +00:00
vmwareapi Fix wrong assertions in unit tests 2019-08-20 13:53:33 +09:00
xenapi xenapi/agent: Change openssl error handling 2019-04-29 12:36:01 +00:00
zvm Share snapshot image membership with instance owner 2019-02-08 18:06:27 -05:00
__init__.py
fakelibosinfo.py Stop sending bad values from libosinfo to libvirt 2019-10-11 08:32:12 +00:00
test_block_device.py Override the 'get' method in DriverBlockDevice class 2019-03-26 11:20:24 +09:00
test_configdrive.py
test_driver.py Remove usage of parameter enforce_type 2017-04-17 20:23:19 +08:00
test_events.py
test_fake.py
test_firewall.py remove get_nw_info_for_instance from compute.utils 2017-06-13 13:30:06 +02:00
test_hardware.py Improve existing flavor and image metadata validation 2019-03-04 14:29:37 -06:00
test_imagecache.py Use uuidsentinel from oslo.utils 2018-09-05 09:08:54 -05:00
test_images.py qemu: Make disk image conversion dramatically faster 2019-03-18 14:53:39 -05:00
test_netutils.py Remove unnecessary code 2017-07-28 06:01:21 +00:00
test_osinfo.py Stop sending bad values from libosinfo to libvirt 2019-10-11 08:32:12 +00:00
test_virt.py Rename block_device_info_get_root 2018-01-11 20:46:13 +00:00
test_virt_drivers.py libvirt: move checking CONF.my_ip to init_host() 2019-07-22 15:48:09 -04:00