diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2021-12-08 16:26:16 +1000 |
---|---|---|
committer | José Expósito <jose.exposito89@gmail.com> | 2021-12-14 08:09:20 +0000 |
commit | 23f5d9074bd6663150b0d36e39dced896d1dc55e (patch) | |
tree | 0b7b888a915c8c41887e803c915b0dfe9999dd1a | |
parent | 1262c81d9b0d560e7b8cbbecdf05b081d7d94f9b (diff) | |
download | libinput-23f5d9074bd6663150b0d36e39dced896d1dc55e.tar.gz |
test: allow for a hold end event when verifying touch motion
Depending on how quick the test suite runs we may get a hold end event
here. Let's silently ignore that one since we aren't interested in it.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | test/test-tablet.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/test-tablet.c b/test/test-tablet.c index bba56b27..d269878f 100644 --- a/test/test-tablet.c +++ b/test/test-tablet.c @@ -5392,7 +5392,13 @@ verify_left_handed_touch_motion(struct litest_device *finger, litest_touch_move_to(finger, 0, x + 1, y - 1, x + 20, y - 20, 10); libinput_dispatch(li); + /* Allow for optional hold gesture to end */ event = libinput_get_event(li); + if (libinput_event_get_type(event) == LIBINPUT_EVENT_GESTURE_HOLD_END) { + libinput_event_destroy(event); + event = libinput_get_event(li); + } + ck_assert_notnull(event); while (event) { |