提交 bd35044b 编写于 作者: A Amos Kong 提交者: Lucas Meneghel Rodrigues

tests.boot: Add a parameter to reboot guest for several times

We touched some bugs when rebooting guest for several times.
Signed-off-by: NAmos Kong <akong@redhat.com>
Signed-off-by: NQingtang Zhou <qzhou@redhat.com>
Acked-by: NFeng Yang <fyang@redhat.com>
Acked-by: NSuqin Huang <shuang@redhat.com>
上级 ed849bb1
......@@ -30,6 +30,8 @@ def run_boot(test, params, env):
error.context("Reboot guest.")
if params["reboot_method"] == "system_reset":
time.sleep(int(params.get("sleep_before_reset", 10)))
session = vm.reboot(session, params["reboot_method"], 0, timeout)
# Reboot the VM
for i in range(int(params.get("reboot_count", 1))):
session = vm.reboot(session, params["reboot_method"], 0, timeout)
session.close()
......@@ -4,6 +4,7 @@
reboot_method = shell
kill_vm_on_error = yes
login_timeout = 240
reboot_count = 25
# this script is used to setup test env for (linux)guest/host
# before performance testing
# rh_perf_envsetup_script = scripts/rh_perf_envsetup.sh
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册