diff -r fae240d633fc -r 6342cbbd1922 test/main.c --- a/test/main.c Tue Oct 17 16:15:41 2017 +0200 +++ b/test/main.c Wed Oct 18 12:03:44 2017 +0200 @@ -232,9 +232,12 @@ ucx_test_run(suite, stdout); fflush(stdout); + + int exit_code = suite->failure > 0 ? EXIT_FAILURE: EXIT_SUCCESS; + ucx_test_suite_free(suite); - return EXIT_SUCCESS; + return exit_code; } else { ucx_test_suite_free(suite); return EXIT_FAILURE;