Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
tp-qemu
提交
e21edb4a
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,发现更多精彩内容 >>
未验证
提交
e21edb4a
编写于
1月 19, 2018
作者:
X
Xu Han
提交者:
GitHub
1月 19, 2018
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #1206 from aliang123/1533797
Remove check_guests_proc_scsi() from verify_qtree()
上级
9f47fed8
c5a4db77
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
5 addition
and
14 deletion
+5
-14
qemu/tests/multi_disk_random_hotplug.py
qemu/tests/multi_disk_random_hotplug.py
+5
-14
未找到文件。
qemu/tests/multi_disk_random_hotplug.py
浏览文件 @
e21edb4a
...
@@ -88,7 +88,7 @@ def run(test, params, env):
...
@@ -88,7 +88,7 @@ def run(test, params, env):
:param params: Dictionary with the test parameters
:param params: Dictionary with the test parameters
:param env: Dictionary with test environment.
:param env: Dictionary with test environment.
"""
"""
def
verify_qtree
(
params
,
info_qtree
,
info_block
,
proc_scsi
,
qdev
):
def
verify_qtree
(
params
,
info_qtree
,
info_block
,
qdev
):
"""
"""
Verifies that params, info qtree, info block and /proc/scsi/ matches
Verifies that params, info qtree, info block and /proc/scsi/ matches
:param params: Dictionary with the test parameters
:param params: Dictionary with the test parameters
...
@@ -97,8 +97,6 @@ def run(test, params, env):
...
@@ -97,8 +97,6 @@ def run(test, params, env):
:type info_qtree: string
:type info_qtree: string
:param info_block: Output of "info block" monitor command
:param info_block: Output of "info block" monitor command
:type info_block: dict of dicts
:type info_block: dict of dicts
:param proc_scsi: Output of "/proc/scsi/scsi" guest file
:type proc_scsi: string
:param qdev: qcontainer representation
:param qdev: qcontainer representation
:type qdev: virttest.qemu_devices.qcontainer.DevContainer
:type qdev: virttest.qemu_devices.qcontainer.DevContainer
"""
"""
...
@@ -110,12 +108,9 @@ def run(test, params, env):
...
@@ -110,12 +108,9 @@ def run(test, params, env):
err
+=
tmp1
+
tmp2
err
+=
tmp1
+
tmp2
err
+=
disks
.
generate_params
()
err
+=
disks
.
generate_params
()
err
+=
disks
.
check_disk_params
(
params
)
err
+=
disks
.
check_disk_params
(
params
)
(
tmp1
,
tmp2
,
_
,
_
)
=
disks
.
check_guests_proc_scsi
(
proc_scsi
)
err
+=
tmp1
+
tmp2
if
err
:
if
err
:
logging
.
error
(
"info qtree:
\n
%s"
,
info_qtree
)
logging
.
error
(
"info qtree:
\n
%s"
,
info_qtree
)
logging
.
error
(
"info block:
\n
%s"
,
info_block
)
logging
.
error
(
"info block:
\n
%s"
,
info_block
)
logging
.
error
(
"/proc/scsi/scsi:
\n
%s"
,
proc_scsi
)
logging
.
error
(
qdev
.
str_bus_long
())
logging
.
error
(
qdev
.
str_bus_long
())
raise
error
.
TestFail
(
"%s errors occurred while verifying"
raise
error
.
TestFail
(
"%s errors occurred while verifying"
" qtree vs. params"
%
err
)
" qtree vs. params"
%
err
)
...
@@ -348,8 +343,7 @@ def run(test, params, env):
...
@@ -348,8 +343,7 @@ def run(test, params, env):
thread
.
join
()
thread
.
join
()
logging
.
debug
(
"All threads finished."
)
logging
.
debug
(
"All threads finished."
)
def
verify_qtree_unsupported
(
params
,
info_qtree
,
info_block
,
proc_scsi
,
def
verify_qtree_unsupported
(
params
,
info_qtree
,
info_block
,
qdev
):
qdev
):
return
logging
.
warn
(
"info qtree not supported. Can't verify qtree vs. "
return
logging
.
warn
(
"info qtree not supported. Can't verify qtree vs. "
"guest disks."
)
"guest disks."
)
...
@@ -421,8 +415,7 @@ def run(test, params, env):
...
@@ -421,8 +415,7 @@ def run(test, params, env):
error
.
context
(
"Verify disk before test"
,
logging
.
info
)
error
.
context
(
"Verify disk before test"
,
logging
.
info
)
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
proc_scsi
=
session
.
cmd_output
(
'cat /proc/scsi/scsi'
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
qdev
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
proc_scsi
,
qdev
)
for
iteration
in
xrange
(
rp_times
):
for
iteration
in
xrange
(
rp_times
):
error
.
context
(
"Hotplugging/unplugging devices, iteration %d"
error
.
context
(
"Hotplugging/unplugging devices, iteration %d"
%
iteration
,
logging
.
info
)
%
iteration
,
logging
.
info
)
...
@@ -447,8 +440,7 @@ def run(test, params, env):
...
@@ -447,8 +440,7 @@ def run(test, params, env):
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
vm
.
verify_alive
()
vm
.
verify_alive
()
proc_scsi
=
session
.
cmd_output
(
'cat /proc/scsi/scsi'
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
qdev
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
proc_scsi
,
qdev
)
qdev
.
set_clean
()
qdev
.
set_clean
()
sub_type
=
params
.
get
(
"sub_type_after_plug"
)
sub_type
=
params
.
get
(
"sub_type_after_plug"
)
...
@@ -476,8 +468,7 @@ def run(test, params, env):
...
@@ -476,8 +468,7 @@ def run(test, params, env):
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_qtree
=
vm
.
monitor
.
info
(
'qtree'
,
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
info_block
=
vm
.
monitor
.
info_block
(
False
)
vm
.
verify_alive
()
vm
.
verify_alive
()
proc_scsi
=
session
.
cmd_output
(
'cat /proc/scsi/scsi'
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
qdev
)
verify_qtree
(
params
,
info_qtree
,
info_block
,
proc_scsi
,
qdev
)
# we verified the unplugs, set the state to 0
# we verified the unplugs, set the state to 0
for
_
in
xrange
(
qdev
.
get_state
()):
for
_
in
xrange
(
qdev
.
get_state
()):
qdev
.
set_clean
()
qdev
.
set_clean
()
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录