diff --git a/KVM/qemu/tdx_basic.cfg b/KVM/qemu/tdx_basic.cfg index 7e122e5c..df267f0a 100644 --- a/KVM/qemu/tdx_basic.cfg +++ b/KVM/qemu/tdx_basic.cfg @@ -7,8 +7,7 @@ # Don't create/remove guest images force_create_image = no remove_image = no - # Automatically start VM - start_vm = yes + start_vm = no # Stop VM after testing kill_vm = yes shell_prompt = "^\[.*\][\#\$]\s*$" diff --git a/KVM/qemu/tests/tdx_basic.py b/KVM/qemu/tests/tdx_basic.py index f896123a..6dbd702a 100644 --- a/KVM/qemu/tests/tdx_basic.py +++ b/KVM/qemu/tests/tdx_basic.py @@ -8,7 +8,7 @@ # History: May. 2024 - Xudong Hao - creation from avocado.utils import process, cpu -from virttest import error_context +from virttest import error_context, env_process from provider.cpu_utils import check_cpu_flags @@ -41,6 +41,8 @@ def run(test, params, env): if tdx_value != "Y": test.fail("TDX is not supported in KVM") + params["start_vm"] = "yes" + env_process.preprocess_vm(test, params, env, params["main_vm"]) vm = env.get_vm(params["main_vm"]) vm.verify_alive() timeout = params.get_numeric("login_timeout", 240)