2016-05-30 16:03:42 +00:00
|
|
|
include_directories(${Libinput_INCLUDE_DIRS})
|
2016-06-02 05:46:09 +00:00
|
|
|
include_directories(${UDEV_INCLUDE_DIR})
|
2016-05-20 13:48:11 +00:00
|
|
|
########################################################
|
|
|
|
# Test Devices
|
|
|
|
########################################################
|
|
|
|
set( testLibinputDevice_SRCS device_test.cpp mock_libinput.cpp ../../libinput/device.cpp )
|
|
|
|
add_executable(testLibinputDevice ${testLibinputDevice_SRCS})
|
2016-05-30 13:06:30 +00:00
|
|
|
target_link_libraries( testLibinputDevice Qt5::Test)
|
2016-05-20 13:48:11 +00:00
|
|
|
add_test(kwin-testLibinputDevice testLibinputDevice)
|
|
|
|
ecm_mark_as_test(testLibinputDevice)
|
2016-05-24 08:57:57 +00:00
|
|
|
|
2016-05-30 15:46:53 +00:00
|
|
|
########################################################
|
|
|
|
# Test Key Event
|
|
|
|
########################################################
|
|
|
|
set( testLibinputKeyEvent_SRCS
|
|
|
|
key_event_test.cpp
|
|
|
|
mock_libinput.cpp
|
|
|
|
../../libinput/device.cpp
|
|
|
|
../../libinput/events.cpp
|
|
|
|
)
|
|
|
|
add_executable(testLibinputKeyEvent ${testLibinputKeyEvent_SRCS})
|
|
|
|
target_link_libraries( testLibinputKeyEvent Qt5::Test Qt5::Widgets KF5::ConfigCore)
|
|
|
|
add_test(kwin-testLibinputKeyEvent testLibinputKeyEvent)
|
|
|
|
ecm_mark_as_test(testLibinputKeyEvent)
|
|
|
|
|
2016-05-31 07:23:12 +00:00
|
|
|
########################################################
|
|
|
|
# Test Pointer Event
|
|
|
|
########################################################
|
|
|
|
set( testLibinputPointerEvent_SRCS
|
|
|
|
pointer_event_test.cpp
|
|
|
|
mock_libinput.cpp
|
|
|
|
../../libinput/device.cpp
|
|
|
|
../../libinput/events.cpp
|
|
|
|
)
|
|
|
|
add_executable(testLibinputPointerEvent ${testLibinputPointerEvent_SRCS})
|
|
|
|
target_link_libraries( testLibinputPointerEvent Qt5::Test Qt5::Widgets KF5::ConfigCore)
|
|
|
|
add_test(kwin-testLibinputPointerEvent testLibinputPointerEvent)
|
|
|
|
ecm_mark_as_test(testLibinputPointerEvent)
|
|
|
|
|
2016-05-31 08:14:28 +00:00
|
|
|
########################################################
|
|
|
|
# Test Touch Event
|
|
|
|
########################################################
|
|
|
|
set( testLibinputTouchEvent_SRCS
|
|
|
|
touch_event_test.cpp
|
|
|
|
mock_libinput.cpp
|
|
|
|
../../libinput/device.cpp
|
|
|
|
../../libinput/events.cpp
|
|
|
|
)
|
|
|
|
add_executable(testLibinputTouchEvent ${testLibinputTouchEvent_SRCS})
|
|
|
|
target_link_libraries( testLibinputTouchEvent Qt5::Test Qt5::Widgets KF5::ConfigCore)
|
|
|
|
add_test(kwin-testLibinputTouchEvent testLibinputTouchEvent)
|
|
|
|
ecm_mark_as_test(testLibinputTouchEvent)
|
|
|
|
|
2016-06-02 05:46:09 +00:00
|
|
|
########################################################
|
|
|
|
# Test Context
|
|
|
|
########################################################
|
|
|
|
set( testLibinputContext_SRCS
|
|
|
|
context_test.cpp
|
|
|
|
mock_libinput.cpp
|
|
|
|
mock_udev.cpp
|
|
|
|
../../libinput/context.cpp
|
|
|
|
../../libinput/device.cpp
|
|
|
|
../../libinput/events.cpp
|
|
|
|
../../libinput/libinput_logging.cpp
|
|
|
|
../../logind.cpp
|
|
|
|
)
|
|
|
|
add_executable(testLibinputContext ${testLibinputContext_SRCS})
|
|
|
|
target_link_libraries( testLibinputContext
|
|
|
|
Qt5::DBus
|
|
|
|
Qt5::Test
|
|
|
|
Qt5::Widgets
|
|
|
|
KF5::ConfigCore
|
|
|
|
KF5::WindowSystem
|
|
|
|
)
|
|
|
|
add_test(kwin-testLibinputContext testLibinputContext)
|
|
|
|
ecm_mark_as_test(testLibinputContext)
|
|
|
|
|
2016-05-24 08:57:57 +00:00
|
|
|
########################################################
|
|
|
|
# Test Input Events
|
|
|
|
########################################################
|
|
|
|
set( testInputEvents_SRCS input_event_test.cpp mock_libinput.cpp ../../libinput/device.cpp ../../input_event.cpp )
|
|
|
|
add_executable(testInputEvents ${testInputEvents_SRCS})
|
|
|
|
target_link_libraries( testInputEvents Qt5::Test Qt5::Gui)
|
|
|
|
add_test(kwin-testInputEvents testInputEvents)
|
|
|
|
ecm_mark_as_test(testInputEvents)
|