diff --git a/autotests/CMakeLists.txt b/autotests/CMakeLists.txt index 101f65990c..85d9733b70 100644 --- a/autotests/CMakeLists.txt +++ b/autotests/CMakeLists.txt @@ -359,8 +359,10 @@ ecm_mark_as_test(testGestures) # Test X11 TimestampUpdate ######################################################## add_executable(testX11TimestampUpdate test_x11_timestamp_update.cpp) +target_compile_definitions(testX11TimestampUpdate PRIVATE KWINBACKENDPATH="${CMAKE_BINARY_DIR}/plugins/platforms/x11/standalone/KWinX11Platform.so") target_link_libraries(testX11TimestampUpdate Qt5::Test + KF5::CoreAddons kwin ) add_test(kwin-testX11TimestampUpdate testX11TimestampUpdate) diff --git a/autotests/test_x11_timestamp_update.cpp b/autotests/test_x11_timestamp_update.cpp index 50ba151d38..f3619d818d 100644 --- a/autotests/test_x11_timestamp_update.cpp +++ b/autotests/test_x11_timestamp_update.cpp @@ -21,6 +21,8 @@ along with this program. If not, see . #include #include +#include + #include "main.h" #include "utils.h" @@ -44,6 +46,7 @@ X11TestApplication::X11TestApplication(int &argc, char **argv) { setX11Connection(QX11Info::connection()); setX11RootWindow(QX11Info::appRootWindow()); + initPlatform(KPluginMetaData(QStringLiteral(KWINBACKENDPATH))); } X11TestApplication::~X11TestApplication()