virstoragetest: testStorageChain: Skip test if filename is NULL

Prepare the test runner for skipping individual tests if images can't be
formatted rather than the whole virstoragetest.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Peter Krempa 2021-09-08 14:10:51 +02:00
parent aa3b29f8fc
commit dad6d609cc

View File

@ -176,6 +176,11 @@ testStorageChain(const void *args)
g_autofree char *expectpath = g_strdup_printf("%s/virstoragetestdata/out/%s",
abs_srcdir, data->testname);
/* If the filename is NULL it means that the images couldn't be created,
* thus skip this particular test. */
if (!data->start)
return EXIT_AM_SKIP;
meta = testStorageFileGetMetadata(data->start, data->format, -1, -1);
if (!meta) {
if (data->flags & EXP_FAIL) {