Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
tp-qemu
提交
f452bf61
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,发现更多精彩内容 >>
提交
f452bf61
编写于
5月 08, 2013
作者:
Q
Qingtang Zhou
提交者:
Lucas Meneghel Rodrigues
5月 08, 2013
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
qemu.tests.cdrom: Update docstring and context
Signed-off-by:
N
Qingtang Zhou
<
qzhou@redhat.com
>
上级
94bb99b8
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
21 addition
and
13 deletion
+21
-13
qemu/tests/cdrom.py
qemu/tests/cdrom.py
+21
-13
未找到文件。
qemu/tests/cdrom.py
浏览文件 @
f452bf61
...
...
@@ -19,19 +19,20 @@ def run_cdrom(test, params, env):
"""
KVM cdrom test:
1) Boot up a VM
with one iso
.
1) Boot up a VM
, with one iso image (optional)
.
2) Check if VM identifies correctly the iso file.
3) * If cdrom_test_autounlock is set, verifies that device is unlocked
<300s after boot
4) Eject cdrom using monitor and change with another iso several times.
5) * If cdrom_test_tray_status = yes, tests tray reporting.
3) Verifies that device is unlocked <300s after boot (optional, if
cdrom_test_autounlock is set).
4) Eject cdrom using monitor.
5) Change cdrom image with another iso several times.
5) Test tray reporting function (optional, if cdrom_test_tray_status is set)
6) Try to format cdrom and check the return string.
7) Mount cdrom device.
8) Copy file from cdrom and compare files
using diff
.
9) Umount and mount several times.
10) Check if the cdrom lock works well when
cdrom
file is not inserted.
This case required the a command line without cdrom file and will be
separated to a different cfg item.
8) Copy file from cdrom and compare files.
9) Umount and mount
cdrom in guest for
several times.
10) Check if the cdrom lock works well when
iso
file is not inserted.
Note: This case requires a qemu cli without setting file property
for -drive option, and will be
separated to a different cfg item.
@param test: kvm test object
@param params: Dictionary with the test parameters
...
...
@@ -43,6 +44,13 @@ def run_cdrom(test, params, env):
after boot (<300s after VM is booted)
@param cfg: cdrom_test_tray_status - Test tray reporting (eject and insert
CD couple of times in guest).
@param cfg: cdrom_test_locked - Test whether cdrom tray lock function
work well in guest.
@param cfg: cdrom_test_eject - Test whether cdrom works well after
several times of eject action.
@param cfg: cdrom_test_file_operation - Test file operation for cdrom,
such as mount/umount, reading files
on cdrom.
@warning: Check dmesg for block device failures
"""
...
...
@@ -64,7 +72,7 @@ def run_cdrom(test, params, env):
@return: path to new iso image file.
"""
error
.
context
(
"
c
reating test iso image '%s'"
%
name
,
logging
.
info
)
error
.
context
(
"
C
reating test iso image '%s'"
%
name
,
logging
.
info
)
cdrom_cd1
=
params
.
get
(
"cdrom_cd1"
)
if
not
os
.
path
.
isabs
(
cdrom_cd1
):
cdrom_cd1
=
os
.
path
.
join
(
data_dir
.
get_data_dir
(),
cdrom_cd1
)
...
...
@@ -83,7 +91,7 @@ def run_cdrom(test, params, env):
def
cleanup_cdrom
(
path
):
""" Removes created iso image """
error
.
context
(
"
c
leaning up temp iso image"
,
logging
.
info
)
error
.
context
(
"
C
leaning up temp iso image"
,
logging
.
info
)
os
.
remove
(
"%s"
%
path
)
...
...
@@ -504,7 +512,7 @@ def run_cdrom(test, params, env):
file_operation_test
(
self
.
session
,
guest_cdrom_device
,
max_test_times
)
error
.
context
(
"Cleanup"
,
logging
.
info
)
error
.
context
(
"Cleanup"
)
# Return the self.iso_image_orig
cdfile
=
get_cdrom_file
(
vm
,
qemu_cdrom_device
)
if
cdfile
!=
self
.
iso_image_orig
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录