tests: Print fakerootdir when it's preserved

Setting the LIBVIRT_SKIP_CLEANUP environment variable results
in the contents of fakerootdir being preserved for inspection.
Be more helpful towards the developer and print out the path
in this case.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Laine Stump <laine@redhat.com>
This commit is contained in:
Andrea Bolognani 2023-03-01 11:11:23 +01:00
parent 87b30e6965
commit 42950d6c4a

View File

@ -790,6 +790,8 @@ virTestFakeRootDirCleanup(char *fakerootdir)
if (!g_getenv("LIBVIRT_SKIP_CLEANUP"))
virFileDeleteTree(fakerootdir);
else
fprintf(stderr, "Test data ready for inspection: %s\n", fakerootdir);
}
int virTestMain(int argc,