Commit graph

9 commits

Author SHA1 Message Date
Peter Hutterer
2edc7e37ac test: mark the protocol A device as touch device
Now that we're emulating everything correctly, let's mark it as proper touch
device.

Two test cases need to be excluded:
- double-down triggers an assert in the test device because this isn't
  possible this way with protocol A devices
- the axisrange warning test can't be triggered, mtdev clips those axes

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2019-03-22 16:23:17 +10:00
Peter Hutterer
5ca1862bde test: add a libinput-test runner for 'deviceless' tests
These are tests that don't need *any* uinput devices at all. Mark them
accordingly and create a new binary that only runs those tests. This way we
can run some of the test suite even in containers where we're restricted.

Better have 10% tested than none, I guess.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2018-06-26 11:18:31 +10:00
Peter Hutterer
ce80e40006 test: move all the _setup() functions into a special section
This way we can loop through them instead of having to add them manually.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2018-03-23 10:17:52 +10:00
Greg V
8adfac3975 Include stdarg.h where variadic functions are used
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-12-01 09:31:42 +10:00
Peter Hutterer
b18f9e6944 test: fix a comment in the log_priority test
We don't rely that the lid switch doesn't work in this test, but we always
print a few things when a device gets successfully added.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-10 19:09:29 +10:00
Peter Hutterer
7e72c8e5bb test: always init the log_handler count and reset it last
When running with -j 1 and CK_FORK=no, the log_handler_count is shared between
the tests. The log_priority tests can invoke the log handler during
libinput_unref(), so on the next day the log handler starts with a nonzero log
handler.

Fix this by always initializing it to 0 in the tests we expect it to be zero
and resetting it last.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-10-06 10:52:57 +10:00
Peter Hutterer
7b5ca6204b Fix a few things scan-build complains about
Uninitialized variables, potential NULL dereferences, dead assignments and an
unused return value.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-10 10:37:58 +10:00
Peter Hutterer
dcbf2c2a44 test: don't leak test warnings to stdout
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-02 10:53:50 +10:00
Peter Hutterer
5d66edc9f4 test: prefix all test source files with "test-"
They weren't originally prefixed but the various tests were, but now that we
only have one test runner binary anyway, the prefix helps sorting the files
easily within e.g. gcov results.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-16 08:59:00 +10:00
Renamed from test/log.c (Browse further)