Merge "Move rebuild notification tests into separate method"
This commit is contained in:
commit
aac977ebd3
|
@ -2,7 +2,7 @@
|
||||||
"event_type":"instance.reboot.end",
|
"event_type":"instance.reboot.end",
|
||||||
"payload":{
|
"payload":{
|
||||||
"nova_object.data":{
|
"nova_object.data":{
|
||||||
"architecture":null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at":"2012-10-29T13:42:11Z",
|
"created_at":"2012-10-29T13:42:11Z",
|
||||||
"deleted_at":null,
|
"deleted_at":null,
|
||||||
|
@ -28,7 +28,7 @@
|
||||||
"auto_disk_config":"MANUAL",
|
"auto_disk_config":"MANUAL",
|
||||||
"kernel_id":"",
|
"kernel_id":"",
|
||||||
"launched_at":"2012-10-29T13:42:11Z",
|
"launched_at":"2012-10-29T13:42:11Z",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"metadata":{},
|
"metadata":{},
|
||||||
"locked":false,
|
"locked":false,
|
||||||
"node":"fake-mini",
|
"node":"fake-mini",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type":"instance.reboot.error",
|
"event_type":"instance.reboot.error",
|
||||||
"payload":{
|
"payload":{
|
||||||
"nova_object.data":{
|
"nova_object.data":{
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at":"2012-10-29T13:42:11Z",
|
"created_at":"2012-10-29T13:42:11Z",
|
||||||
"deleted_at":null,
|
"deleted_at":null,
|
||||||
|
@ -38,7 +38,7 @@
|
||||||
"auto_disk_config":"MANUAL",
|
"auto_disk_config":"MANUAL",
|
||||||
"kernel_id":"",
|
"kernel_id":"",
|
||||||
"launched_at":"2012-10-29T13:42:11Z",
|
"launched_at":"2012-10-29T13:42:11Z",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"metadata":{},
|
"metadata":{},
|
||||||
"locked":false,
|
"locked":false,
|
||||||
"node":"fake-mini",
|
"node":"fake-mini",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type":"instance.reboot.start",
|
"event_type":"instance.reboot.start",
|
||||||
"payload":{
|
"payload":{
|
||||||
"nova_object.data":{
|
"nova_object.data":{
|
||||||
"architecture":null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at":"2012-10-29T13:42:11Z",
|
"created_at":"2012-10-29T13:42:11Z",
|
||||||
"deleted_at":null,
|
"deleted_at":null,
|
||||||
|
@ -28,7 +28,7 @@
|
||||||
"auto_disk_config":"MANUAL",
|
"auto_disk_config":"MANUAL",
|
||||||
"kernel_id":"",
|
"kernel_id":"",
|
||||||
"launched_at":"2012-10-29T13:42:11Z",
|
"launched_at":"2012-10-29T13:42:11Z",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"metadata":{},
|
"metadata":{},
|
||||||
"locked":false,
|
"locked":false,
|
||||||
"node":"fake-mini",
|
"node":"fake-mini",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type": "instance.volume_attach.end",
|
"event_type": "instance.volume_attach.end",
|
||||||
"payload": {
|
"payload": {
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at": "2012-10-29T13:42:11Z",
|
"created_at": "2012-10-29T13:42:11Z",
|
||||||
"deleted_at": null,
|
"deleted_at": null,
|
||||||
|
@ -33,7 +33,7 @@
|
||||||
},
|
},
|
||||||
"host": "compute",
|
"host": "compute",
|
||||||
"host_name": "some-server",
|
"host_name": "some-server",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"ip_addresses": [{
|
"ip_addresses": [{
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"address": "192.168.1.3",
|
"address": "192.168.1.3",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type": "instance.volume_attach.error",
|
"event_type": "instance.volume_attach.error",
|
||||||
"payload": {
|
"payload": {
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at": "2012-10-29T13:42:11Z",
|
"created_at": "2012-10-29T13:42:11Z",
|
||||||
"deleted_at": null,
|
"deleted_at": null,
|
||||||
|
@ -43,7 +43,7 @@
|
||||||
},
|
},
|
||||||
"host": "compute",
|
"host": "compute",
|
||||||
"host_name": "some-server",
|
"host_name": "some-server",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"ip_addresses": [{
|
"ip_addresses": [{
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"address": "192.168.1.3",
|
"address": "192.168.1.3",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type": "instance.volume_attach.start",
|
"event_type": "instance.volume_attach.start",
|
||||||
"payload": {
|
"payload": {
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at": "2012-10-29T13:42:11Z",
|
"created_at": "2012-10-29T13:42:11Z",
|
||||||
"deleted_at": null,
|
"deleted_at": null,
|
||||||
|
@ -33,7 +33,7 @@
|
||||||
},
|
},
|
||||||
"host": "compute",
|
"host": "compute",
|
||||||
"host_name": "some-server",
|
"host_name": "some-server",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"ip_addresses": [{
|
"ip_addresses": [{
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"address": "192.168.1.3",
|
"address": "192.168.1.3",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type": "instance.volume_detach.end",
|
"event_type": "instance.volume_detach.end",
|
||||||
"payload": {
|
"payload": {
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at": "2012-10-29T13:42:11Z",
|
"created_at": "2012-10-29T13:42:11Z",
|
||||||
"deleted_at": null,
|
"deleted_at": null,
|
||||||
|
@ -33,7 +33,7 @@
|
||||||
},
|
},
|
||||||
"host": "compute",
|
"host": "compute",
|
||||||
"host_name": "some-server",
|
"host_name": "some-server",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"ip_addresses": [{
|
"ip_addresses": [{
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"address": "192.168.1.3",
|
"address": "192.168.1.3",
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"event_type": "instance.volume_detach.start",
|
"event_type": "instance.volume_detach.start",
|
||||||
"payload": {
|
"payload": {
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"architecture": null,
|
"architecture": "x86_64",
|
||||||
"availability_zone": "nova",
|
"availability_zone": "nova",
|
||||||
"created_at": "2012-10-29T13:42:11Z",
|
"created_at": "2012-10-29T13:42:11Z",
|
||||||
"deleted_at": null,
|
"deleted_at": null,
|
||||||
|
@ -33,7 +33,7 @@
|
||||||
},
|
},
|
||||||
"host": "compute",
|
"host": "compute",
|
||||||
"host_name": "some-server",
|
"host_name": "some-server",
|
||||||
"image_uuid": "a2459075-d96c-40d5-893e-577ff92e721c",
|
"image_uuid": "155d900f-4e14-4e4c-a73d-069cbf4541e6",
|
||||||
"ip_addresses": [{
|
"ip_addresses": [{
|
||||||
"nova_object.data": {
|
"nova_object.data": {
|
||||||
"address": "192.168.1.3",
|
"address": "192.168.1.3",
|
||||||
|
|
|
@ -75,7 +75,6 @@ class TestInstanceNotificationSample(
|
||||||
self._test_revert_server,
|
self._test_revert_server,
|
||||||
self._test_resize_confirm_server,
|
self._test_resize_confirm_server,
|
||||||
self._test_snapshot_server,
|
self._test_snapshot_server,
|
||||||
self._test_rebuild_server,
|
|
||||||
self._test_reboot_server,
|
self._test_reboot_server,
|
||||||
self._test_reboot_server_error,
|
self._test_reboot_server_error,
|
||||||
self._test_trigger_crash_dump,
|
self._test_trigger_crash_dump,
|
||||||
|
@ -570,7 +569,17 @@ class TestInstanceNotificationSample(
|
||||||
'uuid': server['id']},
|
'uuid': server['id']},
|
||||||
actual=fake_notifier.VERSIONED_NOTIFICATIONS[1])
|
actual=fake_notifier.VERSIONED_NOTIFICATIONS[1])
|
||||||
|
|
||||||
def _test_rebuild_server(self, server):
|
def test_rebuild_server(self):
|
||||||
|
# NOTE(gabor_antal): Rebuild changes the image used by the instance,
|
||||||
|
# therefore the actions tested in test_instance_action had to be in
|
||||||
|
# specific order. To avoid this problem, rebuild was moved from
|
||||||
|
# test_instance_action to its own method.
|
||||||
|
|
||||||
|
server = self._boot_a_server(
|
||||||
|
extra_params={'networks': [{'port': self.neutron.port_1['id']}]})
|
||||||
|
|
||||||
|
fake_notifier.reset()
|
||||||
|
|
||||||
post = {
|
post = {
|
||||||
'rebuild': {
|
'rebuild': {
|
||||||
'imageRef': 'a2459075-d96c-40d5-893e-577ff92e721c',
|
'imageRef': 'a2459075-d96c-40d5-893e-577ff92e721c',
|
||||||
|
|
Loading…
Reference in New Issue