diff options
Diffstat (limited to 'userspace/src/unit_main.c')
-rw-r--r-- | userspace/src/unit_main.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/userspace/src/unit_main.c b/userspace/src/unit_main.c index 31c31d50..64344bf0 100644 --- a/userspace/src/unit_main.c +++ b/userspace/src/unit_main.c | |||
@@ -72,5 +72,13 @@ int main(int argc, char **argv) | |||
72 | 72 | ||
73 | core_print_test_status(fw); | 73 | core_print_test_status(fw); |
74 | 74 | ||
75 | if (fw->results->nr_tests == 0) { | ||
76 | /* No tests were run */ | ||
77 | return -1; | ||
78 | } else if ((fw->results->nr_tests - fw->results->nr_passing) != 0) { | ||
79 | /* Some tests failed */ | ||
80 | return -1; | ||
81 | } | ||
82 | |||
75 | return 0; | 83 | return 0; |
76 | } | 84 | } |