Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
tp-qemu
提交
6e908d28
T
tp-qemu
项目概览
openeuler
/
tp-qemu
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
tp-qemu
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
6e908d28
编写于
10月 20, 2017
作者:
X
Xu Han
提交者:
GitHub
10月 20, 2017
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #1100 from lijinlijin/viorng_in_use
viorng_in_use: Live migration while rng device in use
上级
5ab81a77
17b5477b
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
13 addition
and
6 deletion
+13
-6
qemu/tests/cfg/viorng_in_use.cfg
qemu/tests/cfg/viorng_in_use.cfg
+3
-0
qemu/tests/driver_in_use.py
qemu/tests/driver_in_use.py
+10
-6
未找到文件。
qemu/tests/cfg/viorng_in_use.cfg
浏览文件 @
6e908d28
...
...
@@ -52,3 +52,6 @@
sub_test = boot
reboot_method = system_reset
sleep_before_reset = 20
- with_live_migration:
sub_test = migration
suppress_exception = no
qemu/tests/driver_in_use.py
浏览文件 @
6e908d28
...
...
@@ -79,7 +79,9 @@ def run(test, params, env):
def
run_subtest
(
sub_type
):
"""
Run sub test. e.g. reboot / system_reset...
Run sub test which include main test and background test.
main test: e.g. reboot/shutdown/migration/stop/cont ...
background test: e.g. rng_bat/balloon_test/netperf ...
:params: sub_type: Sub test.
"""
...
...
@@ -97,15 +99,15 @@ def run(test, params, env):
env
[
"bg_status"
]
=
0
run_bg_flag
=
params
.
get
(
"run_bg_flag"
)
sub_type
=
params
[
"sub_test"
]
main_test
=
params
[
"sub_test"
]
bg_stress_test
=
params
[
"run_bgstress"
]
wait_time
=
float
(
params
.
get
(
"wait_bg_time"
,
60
))
suppress_exception
=
params
.
get
(
"suppress_exception"
,
"no"
)
==
"yes"
error_context
.
context
(
"Run %s %s %s"
%
(
sub_type
,
run_bg_flag
,
error_context
.
context
(
"Run %s %s %s"
%
(
main_test
,
run_bg_flag
,
bg_stress_test
),
logging
.
info
)
if
run_bg_flag
==
"before_bg_test"
:
run_subtest
(
sub_type
)
run_subtest
(
main_test
)
if
vm
.
is_dead
():
vm
.
create
(
params
=
params
)
run_subtest
(
bg_stress_test
)
...
...
@@ -114,13 +116,15 @@ def run(test, params, env):
stop_time
=
time
.
time
()
+
wait_time
while
time
.
time
()
<
stop_time
:
if
env
[
"bg_status"
]
==
1
:
run_subtest
(
sub_type
)
run_subtest
(
main_test
)
break
if
stress_thread
:
stress_thread
.
join
(
timeout
=
timeout
,
suppress_exception
=
suppress_exception
)
if
vm
.
is_alive
():
run_subtest
(
bg_stress_test
)
elif
run_bg_flag
==
"after_bg_test"
:
run_subtest
(
bg_stress_test
)
if
vm
.
is_dead
():
vm
.
create
(
params
=
params
)
run_subtest
(
sub_type
)
run_subtest
(
main_test
)
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录