Add wait_for_server_termination in test_server_basic_ops
In test_server_basic_ops, the last step is "delete_server" and
without any further check. The pure "delete_server" is of no
use because there already exists addCleanup in self.create_server.
On the other hand, if we want to check whether the server can
be deleted properly, we should add wait_for_server_termination
after delete_server, thus it can raise an exception if the server
ends with unexpected ERROR state.
Change-Id: I2efa0f94faaa6adce5d9b559143456d060911125
diff --git a/tempest/scenario/test_server_basic_ops.py b/tempest/scenario/test_server_basic_ops.py
index c66128d..3aab2b8 100644
--- a/tempest/scenario/test_server_basic_ops.py
+++ b/tempest/scenario/test_server_basic_ops.py
@@ -16,6 +16,7 @@
import json
import re
+from tempest.common import waiters
from tempest import config
from tempest import exceptions
from tempest.lib.common.utils import test_utils
@@ -134,3 +135,5 @@
self.verify_metadata_on_config_drive()
self.verify_networkdata_on_config_drive()
self.servers_client.delete_server(self.instance['id'])
+ waiters.wait_for_server_termination(
+ self.servers_client, self.instance['id'], ignore_error=False)