]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
tests: do not include skipped tests in failedTests
authorJán Tomko <jtomko@redhat.com>
Wed, 4 Mar 2020 15:48:27 +0000 (16:48 +0100)
committerJán Tomko <jtomko@redhat.com>
Wed, 4 Mar 2020 16:18:51 +0000 (17:18 +0100)
We recognize three return values from tests:
* OK    -> 0
* SKIP  -> EXIT_AM_SKIP
* ERROR -> anything else

Also check for EXIT_AM_SKIP when building a bitmap of failed tests,
otherwise the skipped tests would be printed in the suggested range
of tests that shoud be re-run.

Reported-by: Peter Krempa <pkrempa@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
Fixes: cebb468ef5e82b8d4253e27ef70c67812cf93c5a
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
tests/testutils.c

index 2f6d65364e69da362772f9c5b2c821f36ed32635..5fd81b70a26a6a2bdc593cf752c25ba0cc1deaf3 100644 (file)
@@ -172,7 +172,7 @@ virTestRun(const char *title,
             fprintf(stderr, "!");
     }
 
-    if (ret != 0)
+    if (ret != 0 && ret != EXIT_AM_SKIP)
         ignore_value(virBitmapSetBitExpand(failedTests, testCounter));
 
     g_unsetenv("VIR_TEST_MOCK_TESTNAME");