From: Serge Hallyn Date: Mon, 2 Jun 2014 13:53:16 +0000 (-0500) Subject: snapshot test: make sure that external snapshot was really created X-Git-Tag: lxc-1.1.0.alpha1~41 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e60e630c4a1e7179a37d3edd7925b59affb45785;p=thirdparty%2Flxc.git snapshot test: make sure that external snapshot was really created Signed-off-by: Serge Hallyn Acked-by: Stéphane Graber --- diff --git a/src/tests/snapshot.c b/src/tests/snapshot.c index 21acd3e72..b035096f1 100644 --- a/src/tests/snapshot.c +++ b/src/tests/snapshot.c @@ -126,6 +126,12 @@ int main(int argc, char *argv[]) goto err; } + c2 = lxc_container_new(RESTNAME, NULL); + if (!c2 || !c2->is_defined(c2)) { + fprintf(stderr, "%s: %d: external snapshot restore failed\n", __FILE__, __LINE__); + goto err; + } + lxc_container_put(c2); c2 = c->clone(c, MYNAME2, NULL, LXC_CLONE_SNAPSHOT, "overlayfs", NULL, 0, NULL); if (!c2) {