]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
testsuite: Exit with success on signal if test has expected_fail=true
authorLucas De Marchi <lucas.de.marchi@gmail.com>
Thu, 21 Mar 2013 05:22:15 +0000 (02:22 -0300)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Thu, 21 Mar 2013 05:22:15 +0000 (02:22 -0300)
testsuite/testsuite.c

index 0b642e27404937bf90d1eb246c98656b810a4b8e..9e7cf0323f6a4fc7e4eb2ae0c2d8258c350b0f39 100644 (file)
@@ -573,7 +573,7 @@ static inline int test_run_parent(const struct test *t, int fdout[2],
        } else if (WIFSIGNALED(err)) {
                ERR("'%s' [%u] terminated by signal %d (%s)\n", t->name, pid,
                                WTERMSIG(err), strsignal(WTERMSIG(err)));
-               return EXIT_FAILURE;
+               return t->expected_fail ? EXIT_SUCCESS : EXIT_FAILURE;
        }
 
        if (matchout)