[PATCH libinput 4/5] test: Prefix litest created device names with litest

Hans de Goede hdegoede at redhat.com
Tue Jun 24 07:23:12 PDT 2014


And add an example xorg.conf.d .conf file for ignoring these devices under
xorg.

Signed-off-by: Hans de Goede <hdegoede at redhat.com>
---
 test/50-litest.conf | 6 ++++++
 test/litest.c       | 4 +++-
 2 files changed, 9 insertions(+), 1 deletion(-)
 create mode 100644 test/50-litest.conf

diff --git a/test/50-litest.conf b/test/50-litest.conf
new file mode 100644
index 0000000..76579d7
--- /dev/null
+++ b/test/50-litest.conf
@@ -0,0 +1,6 @@
+# Ignore devices created by libinput's test suite (litest)
+Section "InputClass"
+        Identifier "libinput test suite blacklist"
+        MatchProduct "litest"
+        Option "Ignore" "on"
+EndSection
diff --git a/test/litest.c b/test/litest.c
index 0a9cc72..dd14edc 100644
--- a/test/litest.c
+++ b/test/litest.c
@@ -818,11 +818,13 @@ litest_create_uinput_device_from_description(const char *name,
 		.flat = 0,
 		.resolution = 100
 	};
+	char buf[512];
 
 	dev = libevdev_new();
 	ck_assert(dev != NULL);
 
-	libevdev_set_name(dev, name);
+	snprintf(buf, sizeof(buf), "litest %s", name);
+	libevdev_set_name(dev, buf);
 	if (id) {
 		libevdev_set_id_bustype(dev, id->bustype);
 		libevdev_set_id_vendor(dev, id->vendor);
-- 
2.0.0



More information about the wayland-devel mailing list