提交 a69e9c3f 编写于 作者: X Xu Tian

qemu.tests: fix cfg typo in drive_mirror

Signed-off-by: NXu Tian <xutian@redhat.com>
上级 fcef3478
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
negative_test = yes negative_test = yes
variants: variants:
- readonly_target: - readonly_target:
create_mode = existing create_mode_target = existing
before_start = readonly_target before_start = readonly_target
before_cleanup = clear_readonly_bit before_cleanup = clear_readonly_bit
- with_stress: - with_stress:
......
...@@ -56,13 +56,13 @@ def run(test, params, env): ...@@ -56,13 +56,13 @@ def run(test, params, env):
simple_test.action_before_start() simple_test.action_before_start()
try: try:
simple_test.start() simple_test.start()
except error.TestFail, detail: except Exception, detail:
if params.get("negative_test") == "yes": if params.get("negative_test") == "yes":
if not re.search(r"No active.*job", str(detail), re.I): keywords = params.get("error_key_words", "Could not open")
raise error.TestFail("Block job not cancelled in" if simple_test.get_status():
"negative testing") raise error.TestFail("Block job not cancel as expect")
break if keywords not in str(detail):
raise raise
simple_test.action_before_steady() simple_test.action_before_steady()
if simple_test.get_status(): if simple_test.get_status():
simple_test.cancel() simple_test.cancel()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册