Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests/hid: wacom: fix confidence tests

The device is exported with a fuzz of 4, meaning that the `+ t` here
is removed by the fuzz algorithm, making those tests failing.

Not sure why, but when I run this locally it was passing, but not in the
VM of the CI.

Fixes: b0fb904d074e ("HID: wacom: Add additional tests of confidence behavior")
Link: https://gitlab.freedesktop.org/bentiss/hid/-/jobs/53692957#L3315
Acked-by: Jason Gerecke <jason.gerecke@wacom.com>
Link: https://lore.kernel.org/r/20240117-b4-wip-wacom-tests-fixes-v1-1-f317784f3c36@kernel.org
Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>

+4 -4
+4 -4
tools/testing/selftests/hid/tests/test_wacom_generic.py
··· 880 880 does not overlap with other contacts. The value of `t` may be 881 881 incremented over time to move the point along a linear path. 882 882 """ 883 - x = 50 + 10 * contact_id + t 884 - y = 100 + 100 * contact_id + t 883 + x = 50 + 10 * contact_id + t * 11 884 + y = 100 + 100 * contact_id + t * 11 885 885 return test_multitouch.Touch(contact_id, x, y) 886 886 887 887 def make_contacts(self, n, t=0): ··· 902 902 tracking_id = contact_ids.tracking_id 903 903 slot_num = contact_ids.slot_num 904 904 905 - x = 50 + 10 * contact_id + t 906 - y = 100 + 100 * contact_id + t 905 + x = 50 + 10 * contact_id + t * 11 906 + y = 100 + 100 * contact_id + t * 11 907 907 908 908 # If the data isn't supposed to be stored in any slots, there is 909 909 # nothing we can check for in the evdev stream.