nova/nova/tests/unit/objects
Balazs Gibizer 5c50a45a1e Fix RequestLevelParams persistence handling in RequestSpec
The request_level_params field of the RequestSpec are intentionally not
persistent and at the same time it is declared as non nullable. The
current code handling the persistence of this field actually set the
request_level_params field to None breaking the non nullable invariant
of the field.

So far this is error is not triggered as the request_level_params field
was only used lazy loading, which is defaulted the field to a new
RequestLevelParam object on the RequestSpec object that was never saved after
such lazy load. A later patch will initialize request_level_params field
in the RequestSpec.from_components() factory method to handle this
parameters from Neutron ports and that triggers a failure when the
RequestSpec is saved.

There are a set of non nullable, non persisted RequestSpec fields that
are handled individually during create / save. This patch applies the
same logic to request_level_params as well.

Change-Id: I7d11ef8abb30686f9d125cac0e48369eab839b0f
2021-05-28 14:26:56 +02:00
..
__init__.py
test_aggregate.py DB API changes to get non-matching aggregates from metadata 2019-09-12 16:56:32 -05:00
test_bandwidth_usage.py Use uuidsentinel from oslo.utils 2018-09-05 09:08:54 -05:00
test_block_device.py fup: Merge duplicate volume attachment checks 2021-02-04 14:05:31 +00:00
test_build_request.py Merge "Fix misuse of nova.objects.base.obj_equal_prims" 2019-08-13 22:08:39 +00:00
test_cell_mapping.py Fix formatting non-templated cell URLs with no config 2018-10-16 16:11:17 -04:00
test_compute_node.py objects: Add 'NUMACell.pcpuset' field 2019-09-18 00:21:10 +01:00
test_console_auth_token.py Remove six.moves 2020-11-07 03:25:02 +00:00
test_diagnostics.py Added nova objects for intance diagnostics 2017-05-30 00:39:44 +04:00
test_ec2.py ec2: Move ec2utils functions to their callers 2019-09-27 15:27:08 +01:00
test_external_event.py Use EnumField for instance external event name 2015-05-20 22:16:52 +00:00
test_fields.py tests: Poison os.uname 2021-02-20 15:32:15 +00:00
test_flavor.py Fix all invalid obj_make_compatible test case 2018-07-27 02:20:46 +00:00
test_host_mapping.py Remove six.text_type (2/2) 2020-12-13 11:26:35 +00:00
test_hv_spec.py objects: Move 'vm_mode' to 'fields.VMMode' 2016-11-25 16:19:44 +00:00
test_image_meta.py libvirt: Add support for virtio-based input devices 2021-03-05 11:00:02 +00:00
test_instance.py image_meta: Provide image_ref as the id when fetching from instance 2021-05-20 16:57:24 +01:00
test_instance_action.py Remove six.text_type (2/2) 2020-12-13 11:26:35 +00:00
test_instance_device_metadata.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
test_instance_fault.py Remove 'instance_fault_create_at_top' 2019-04-29 17:54:17 +01:00
test_instance_group.py Avoid unnecessary joins in InstanceGroup.get_hosts 2019-05-23 11:14:55 -04:00
test_instance_info_cache.py Remove 'instance_info_cache_update_at_top' 2019-04-29 17:55:41 +01:00
test_instance_mapping.py Raise InstanceMappingNotFound if StaleDataError is encountered 2020-06-24 20:29:44 +00:00
test_instance_numa.py objects: Fix issue in exception type 2020-10-12 10:09:10 +01:00
test_instance_pci_requests.py Remove stale nested backport from InstancePCIRequests 2020-04-21 09:07:32 -07:00
test_keypair.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
test_migrate_data.py objects: Remove 'XenapiLiveMigrateData' 2020-09-11 14:09:06 +01:00
test_migration.py Join migration_context and flavor in Migration.instance 2019-10-21 13:00:59 -04:00
test_migration_context.py Fix accumulated non-docs nits for cross-cell-resize series 2019-12-23 10:10:57 -05:00
test_monitor_metric.py Fix MonitorMetric obj_make_compatible 2016-09-12 14:10:41 +00:00
test_network_request.py nova-net: Remove final references to nova-network 2020-01-08 13:54:12 +00:00
test_numa.py libvirt: start tracking NUMACell.socket for hosts 2021-02-21 11:30:07 -05:00
test_objects.py objects: Add 'VDPA' to 'PciDeviceType' 2021-03-11 09:40:04 +00:00
test_pci_device.py pci: Add vDPA vnic to PCI request mapping and filtering 2021-03-16 20:39:26 +00:00
test_pci_device_pool.py Return empty PciDevicePoolList obj instead of None 2015-09-11 21:20:01 +02:00
test_quotas.py nova-net: Remove 'networks' quota 2019-11-22 16:49:31 +00:00
test_request_spec.py Fix RequestLevelParams persistence handling in RequestSpec 2021-05-28 14:26:56 +02:00
test_resource.py Remove six.text_type (2/2) 2020-12-13 11:26:35 +00:00
test_security_group.py Fix ovo compatibility code unit tests 2019-01-16 15:51:22 +01:00
test_selection.py Add Selection.availability_zone field 2019-10-02 13:39:24 -04:00
test_service.py Remove six.text_type (2/2) 2020-12-13 11:26:35 +00:00
test_tag.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
test_task_log.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
test_trusted_certs.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
test_vcpu_model.py objects: Move 'cpumodel' to 'fields.CPU*' 2016-11-25 16:19:43 +00:00
test_virt_cpu_topology.py Convert hardware.VirtCPUTopology to nova object 2014-11-20 09:14:25 -05:00
test_virtual_interface.py Use uuidsentinel from oslo.utils 2018-09-05 09:08:54 -05:00
test_volume_usage.py Use uuidsentinel from oslo.utils 2018-09-05 09:08:54 -05:00