From 572ac54250fdd1a61809b57cbd15a49209c83f16 Mon Sep 17 00:00:00 2001 From: Jorge San Emeterio Date: Thu, 9 Mar 2023 10:38:56 +0000 Subject: Update "test_list_migrations_in_flavor_resize_situation" to indicate the failing request on timeout. This is one of those tests that for some reason or the other fail randomly on our CI systems. Problem is, that the error message it fails with is not very helpful, as it just indicates that a timeout happened but not much else. This change seeks to fix that by including the request id that led to the timeout. This way, once the test fails on a build, it will be possible to search the log files for this request and track the underlying problem. Closes-Bug: #2009701 Change-Id: Ic1ffd62f9d6ed0d69467f678c1820cddbb1fda12 --- tempest/api/compute/base.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tempest/api/compute/base.py b/tempest/api/compute/base.py index 260d4e05f..b1bfac773 100644 --- a/tempest/api/compute/base.py +++ b/tempest/api/compute/base.py @@ -462,9 +462,11 @@ class BaseV2ComputeTest(api_version_utils.BaseMicroversionTest, self, server_id, new_flavor_id, wait_until='ACTIVE', **kwargs ): """resize and confirm_resize an server, waits for it to be ACTIVE.""" - self.servers_client.resize_server(server_id, new_flavor_id, **kwargs) - waiters.wait_for_server_status(self.servers_client, server_id, - 'VERIFY_RESIZE') + body = self.servers_client.resize_server( + server_id, new_flavor_id, **kwargs) + waiters.wait_for_server_status( + self.servers_client, server_id, 'VERIFY_RESIZE', + request_id=body.response['x-openstack-request-id']) self.servers_client.confirm_resize_server(server_id) waiters.wait_for_server_status( -- cgit v1.2.1