diff --git a/test/litest.c b/test/litest.c index fc3e8b57..c4797802 100644 --- a/test/litest.c +++ b/test/litest.c @@ -2353,8 +2353,8 @@ litest_wait_for_event_of_type(struct libinput *li, ...) struct libinput_event *event; while ((type = libinput_next_event_type(li)) == LIBINPUT_EVENT_NONE) { - int rc = poll(&fds, 1, -1); - litest_assert_int_gt(rc, -1); + int rc = poll(&fds, 1, 2000); + litest_assert_int_gt(rc, 0); libinput_dispatch(li); }