summaryrefslogtreecommitdiff
path: root/src/init/tests/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/init/tests/main.c')
-rw-r--r--src/init/tests/main.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/init/tests/main.c b/src/init/tests/main.c
index 239ed3e..eb7c23f 100644
--- a/src/init/tests/main.c
+++ b/src/init/tests/main.c
@@ -15,7 +15,11 @@ static void run_forked(void (*fn)()) {
if (!_syscall_fork()) {
fn();
_syscall_exit(0);
- } else _syscall_await();
+ } else {
+ /* successful tests must return 0
+ * TODO add a better fail msg */
+ if (_syscall_await() != 0) test_fail();
+ }
}