From 4a202a95c0a2ed2cda86ba52eb939ef44f20af5f Mon Sep 17 00:00:00 2001 From: satrmb <10471-satrmb_true-email-is-private_contact-via-web@gitlab.freedesktop.org> Date: Tue, 28 Jun 2022 13:02:22 +0200 Subject: [PATCH] test: exclude the two high-delay debounce tests from the valgrind CI run The `debounce_bounce_high_delay` and `debounce_spurious_trigger_high_delay` tests are failing with annoying frequency in valgrind, but that is entirely due to valgrind being too slow for the tight timing reqirements of these tests. Skipping them in valgrind has next to no potential to hide memory leaks because the code paths leading to success are also covered by other tests which are less picky about timing, and the CI test suite run without valgrind still tests for their success. Signed-off-by: satrmb <10471-satrmb@users.noreply.gitlab.freedesktop.org> --- test/test-pointer.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/test/test-pointer.c b/test/test-pointer.c index 5d5d2fb9..ee675f39 100644 --- a/test/test-pointer.c +++ b/test/test-pointer.c @@ -30,6 +30,7 @@ #include #include #include +#include #include "libinput-util.h" #include "litest.h" @@ -3657,11 +3658,14 @@ TEST_COLLECTION(pointer) litest_add(pointer_time_usec, LITEST_RELATIVE, LITEST_ANY); litest_add_ranged(debounce_bounce, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE, &buttons); - litest_add_ranged(debounce_bounce_high_delay, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE, &buttons); + /* Timing-sensitive test, valgrind is too slow */ + if (!RUNNING_ON_VALGRIND) + litest_add_ranged(debounce_bounce_high_delay, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE, &buttons); litest_add(debounce_bounce_check_immediate, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); litest_add_ranged(debounce_spurious, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE, &buttons); litest_add(debounce_spurious_multibounce, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); - litest_add(debounce_spurious_trigger_high_delay, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); + if (!RUNNING_ON_VALGRIND) + litest_add(debounce_spurious_trigger_high_delay, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); litest_add(debounce_spurious_dont_enable_on_otherbutton, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); litest_add(debounce_spurious_cancel_debounce_otherbutton, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE); litest_add(debounce_spurious_switch_to_otherbutton, LITEST_BUTTON, LITEST_TOUCHPAD|LITEST_NO_DEBOUNCE);