4b783a206c
To remove duplicated data this patch introduce common json fragments for the instance related notifications and refactors the sample file of instance.delete.start and instance.delete.end. The common sample fragments define an active instance as that is the most common state in the instance action notifications. This way we can minimize the difference between the common sample and the generated notification. Still there will be differences. For example instance.delete.end notification will contain different instance status and some other deletion related fields are also set. To make sure the the sample matches with the generated notification we have to override some of the fields coming from the common sample fragment. Such overrides could be added in the test case directly to the _verify_notification() call as it is done in case of dynamic values like instance uuid. However the sample files not only used in the functional tests but also during the generation of the notification dev-ref. To have meaningful samples in the doc we have to do such overrides during the reference resolving and not directly in the test case. Change-Id: I0669a075c94ba2a435116791e3391d8d745bc639
13 lines
337 B
JSON
13 lines
337 B
JSON
{
|
|
"nova_object.data": {
|
|
"boot_index": null,
|
|
"delete_on_termination": false,
|
|
"device_name": "/dev/sdb",
|
|
"tag": null,
|
|
"volume_id": "a07f71dc-8151-4e7d-a0cc-cd24a3f11113"
|
|
},
|
|
"nova_object.name": "BlockDevicePayload",
|
|
"nova_object.namespace": "nova",
|
|
"nova_object.version": "1.0"
|
|
}
|