[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 2/3] tests: Add an option for snapshot (default: off
From: |
Fam Zheng |
Subject: |
[Qemu-devel] [PATCH 2/3] tests: Add an option for snapshot (default: off) |
Date: |
Wed, 4 Apr 2018 10:52:00 +0800 |
Not using snapshot has the benefit of automatically persisting useful
test harnesses, such as docker images and ccache database. Although it
will lose some cleanness, it is imaginably useful for patchew.
Signed-off-by: Fam Zheng <address@hidden>
---
tests/vm/basevm.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py
index 686d88decf..960e13f349 100755
--- a/tests/vm/basevm.py
+++ b/tests/vm/basevm.py
@@ -218,6 +218,8 @@ def parse_args(vm_name):
help="build QEMU from source in guest")
parser.add_option("--interactive", "-I", action="store_true",
help="Interactively run command")
+ parser.add_option("--snapshot", "-s", action="store_true",
+ help="run tests with a snapshot")
parser.disable_interspersed_args()
return parser.parse_args()
@@ -243,7 +245,10 @@ def main(vmcls):
jobs=args.jobs)]
else:
cmd = argv
- vm.boot(args.image + ",snapshot=on")
+ img = args.image
+ if args.snapshot:
+ img += ",snapshot=on"
+ vm.boot(img)
vm.wait_ssh()
except Exception as e:
if isinstance(e, SystemExit) and e.code == 0:
--
2.14.3
[Qemu-devel] [PATCH 2/3] tests: Add an option for snapshot (default: off),
Fam Zheng <=
[Qemu-devel] [PATCH 3/3] tests: Add centos VM testing, Fam Zheng, 2018/04/03
Re: [Qemu-devel] [PATCH 0/3] Add a CentOS test image to run docker tests, no-reply, 2018/04/03
Re: [Qemu-devel] [PATCH 0/3] Add a CentOS test image to run docker tests, no-reply, 2018/04/04
Re: [Qemu-devel] [PATCH 0/3] Add a CentOS test image to run docker tests, Peter Xu, 2018/04/04
Re: [Qemu-devel] [PATCH 0/3] Add a CentOS test image to run docker tests, Daniel P . Berrangé, 2018/04/04
Re: [Qemu-devel] [PATCH 0/3] Add a CentOS test image to run docker tests, Paolo Bonzini, 2018/04/06