mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-03-21 09:50:44 +01:00
test: mark the thinkpad extrabuttons device as ID_INPUT_SWITCH
This is supposed to come from systemd on a real setup, but for our test setup we want to pass the test suite even when the system itself doesn't set it.
This commit is contained in:
parent
6adb336829
commit
187e33f5da
1 changed files with 10 additions and 0 deletions
|
|
@ -70,6 +70,15 @@ static int events[] = {
|
|||
-1, -1,
|
||||
};
|
||||
|
||||
static const char udev_rule[] =
|
||||
"ACTION==\"remove\", GOTO=\"switch_end\"\n"
|
||||
"KERNEL!=\"event*\", GOTO=\"switch_end\"\n"
|
||||
"\n"
|
||||
"ATTRS{name}==\"litest ThinkPad Extra Buttons*\",\\\n"
|
||||
" ENV{ID_INPUT_SWITCH}=\"1\"\n"
|
||||
"\n"
|
||||
"LABEL=\"switch_end\"";
|
||||
|
||||
TEST_DEVICE("thinkpad-extrabuttons",
|
||||
.type = LITEST_THINKPAD_EXTRABUTTONS,
|
||||
.features = LITEST_KEYS | LITEST_SWITCH,
|
||||
|
|
@ -79,4 +88,5 @@ TEST_DEVICE("thinkpad-extrabuttons",
|
|||
.id = &input_id,
|
||||
.events = events,
|
||||
.absinfo = NULL,
|
||||
.udev_rule = udev_rule,
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue