Skip to content

Commit

Permalink
test: make most tests portable by copying linux/input.h locally
Browse files Browse the repository at this point in the history
There is really no reason to deny these tests from different platforms
only for a few #defines.

The only linux-only test (or test program, it is not run by make check)
is interactive-evdev, which actually uses evdev.

Signed-off-by: Ran Benita <ran234@gmail.com>
  • Loading branch information
bluetech committed Sep 6, 2014
1 parent e95fb47 commit ba98562
Show file tree
Hide file tree
Showing 5 changed files with 599 additions and 13 deletions.
18 changes: 9 additions & 9 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,8 @@ libtest_la_CFLAGS = $(AM_CFLAGS) -fvisibility=default
libtest_la_SOURCES = \
$(libxkbcommon_la_SOURCES) \
test/common.c \
test/test.h
test/test.h \
test/evdev-scancodes.h

AM_TESTS_ENVIRONMENT = \
XKB_LOG_LEVEL=debug; export XKB_LOG_LEVEL; \
Expand All @@ -173,7 +174,10 @@ TESTS = \
test/buffercomp \
test/log \
test/atom \
test/utf8
test/utf8 \
test/state \
test/keyseq \
test/rulescomp
check_PROGRAMS = \
test/rmlvo-to-kccgst \
test/print-compiled-keymap \
Expand All @@ -191,21 +195,17 @@ test_buffercomp_LDADD = $(TESTS_LDADD)
test_log_LDADD = $(TESTS_LDADD)
test_atom_LDADD = $(TESTS_LDADD)
test_utf8_LDADD = $(TESTS_LDADD)
test_state_LDADD = $(TESTS_LDADD)
test_keyseq_LDADD = $(TESTS_LDADD)
test_rulescomp_LDADD = $(TESTS_LDADD) -lrt
test_rmlvo_to_kccgst_LDADD = $(TESTS_LDADD)
test_print_compiled_keymap_LDADD = $(TESTS_LDADD)
test_bench_key_proc_LDADD = $(TESTS_LDADD) -lrt

if BUILD_LINUX_TESTS
TESTS += \
test/state \
test/keyseq \
test/rulescomp
check_PROGRAMS += \
test/interactive-evdev

test_state_LDADD = $(TESTS_LDADD)
test_keyseq_LDADD = $(TESTS_LDADD)
test_rulescomp_LDADD = $(TESTS_LDADD) -lrt
test_interactive_evdev_LDADD = $(TESTS_LDADD)
endif BUILD_LINUX_TESTS

Expand Down

0 comments on commit ba98562

Please sign in to comment.