From: Pavel Hrdina Date: Thu, 11 Nov 2021 16:36:06 +0000 (+0100) Subject: test: snapshot revert: always emulate VM process stop X-Git-Tag: v7.10.0-rc1~53 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5bed5db990c1f6dce04f8e5a3854f76b7d06ddec;p=thirdparty%2Flibvirt.git test: snapshot revert: always emulate VM process stop Reflect the same change in test driver as in QEMU driver because the compatibility check code isn't perfect. Signed-off-by: Pavel Hrdina Reviewed-by: Peter Krempa --- diff --git a/src/test/test_driver.c b/src/test/test_driver.c index 985f08ea1f..a76b207c0e 100644 --- a/src/test/test_driver.c +++ b/src/test/test_driver.c @@ -9076,28 +9076,13 @@ testDomainRevertToSnapshot(virDomainSnapshotPtr snapshot, if (virDomainObjIsActive(vm)) { /* Transitions 5, 6, 8, 9 */ - /* Check for ABI compatibility. */ - if (!virDomainDefCheckABIStability(vm->def, config, - privconn->xmlopt)) { - virErrorPtr err = virGetLastError(); - - if (!(flags & VIR_DOMAIN_SNAPSHOT_REVERT_FORCE)) { - /* Re-spawn error using correct category. */ - if (err->code == VIR_ERR_CONFIG_UNSUPPORTED) - virReportError(VIR_ERR_SNAPSHOT_REVERT_RISKY, "%s", - err->str2); - goto cleanup; - } - - virResetError(err); - testDomainShutdownState(snapshot->domain, vm, - VIR_DOMAIN_SHUTOFF_FROM_SNAPSHOT); - event = virDomainEventLifecycleNewFromObj(vm, - VIR_DOMAIN_EVENT_STOPPED, - VIR_DOMAIN_EVENT_STOPPED_FROM_SNAPSHOT); - virObjectEventStateQueue(privconn->eventState, event); - goto load; - } + testDomainShutdownState(snapshot->domain, vm, + VIR_DOMAIN_SHUTOFF_FROM_SNAPSHOT); + event = virDomainEventLifecycleNewFromObj(vm, + VIR_DOMAIN_EVENT_STOPPED, + VIR_DOMAIN_EVENT_STOPPED_FROM_SNAPSHOT); + virObjectEventStateQueue(privconn->eventState, event); + goto load; if (virDomainObjGetState(vm, NULL) == VIR_DOMAIN_RUNNING) { /* Transitions 5, 6 */