ironic/ironic/tests/unit/drivers
Richard Pioso 6d6cf18f31 DRAC get_bios_config() passthru causes exception
The DRAC driver's (pxe_drac) get_bios_config() vendor passthru method
raises an AttributeError exception. It no longer returns the current
BIOS configuration. This is a regression from stable/mitaka.

Triage found that get_bios_config() mistakenly treats the value returned
by python-dracclient's list_bios_settings() as containing named tuples.
When it calls the namedtuple _asdict() method, an AttributeError
exception is raised.

Revert get_bios_config()'s handling of the return value to use __dict__.
Remove the comment that is not consistent with the implementation.

Also revert the unit test case for a successful call to use mock to
create the return value. Use mock.NonCallableMock with an empty
specification (spec) to catch this type of bug in the future.

Change-Id: I94afaa72a1ef25efc1b622e29e3a92a5d27f1892
Closes-Bug: #1637671
2016-10-31 15:00:32 -04:00
..
modules DRAC get_bios_config() passthru causes exception 2016-10-31 15:00:32 -04:00
__init__.py Prepare for functional testing 2015-09-28 21:27:01 +00:00
elilo_efi_pxe_config.template Cleanup unused (i)PXE kernel parameters 2016-10-06 17:16:31 +03:00
ipxe_config.template Remove "dhcp" command from the iPXE template 2016-10-20 18:02:46 +02:00
ipxe_config_timeout.template Remove "dhcp" command from the iPXE template 2016-10-20 18:02:46 +02:00
pxe_config.template Cleanup unused (i)PXE kernel parameters 2016-10-06 17:16:31 +03:00
pxe_grub_config.template Cleanup unused (i)PXE kernel parameters 2016-10-06 17:16:31 +03:00
test_agent.py IPMITool: add IPMISocatConsole and IPMIConsole class 2016-07-25 16:42:31 +09:00
test_base.py Introduce new driver call and RPC for heartbeat 2016-06-27 15:26:10 +02:00
test_fake.py Fix fake.FakeBoot.prepare_ramdisk() signature 2016-07-15 16:36:37 +03:00
test_irmc.py Remove iterated form of side effects 2016-07-07 10:08:55 +09:00
test_pxe.py IPMITool: add IPMISocatConsole and IPMIConsole class 2016-07-25 16:42:31 +09:00
test_utils.py Pass swiftclient header values as strings 2016-08-19 10:10:01 -07:00
third_party_driver_mock_specs.py Switch Inspector interface to pass keystoneauth sessions 2016-08-22 18:04:29 +02:00
third_party_driver_mocks.py Switch Inspector interface to pass keystoneauth sessions 2016-08-22 18:04:29 +02:00