diff --git a/autotests/CMakeLists.txt b/autotests/CMakeLists.txt index ca25e5712..a8481822b 100644 --- a/autotests/CMakeLists.txt +++ b/autotests/CMakeLists.txt @@ -49,8 +49,10 @@ PLASMA_UNIT_TESTS( add_executable(storagetest storagetest.cpp ../src/plasma/private/storage.cpp ../src/plasma/private/storagethread.cpp) target_link_libraries(storagetest Qt5::Gui Qt5::Test Qt5::Sql KF5::KIOCore KF5::Plasma KF5::CoreAddons) -set(dialogtest_srcs dialognativetest.cpp) -ecm_add_test(${dialogtest_srcs} TEST_NAME dialogtest LINK_LIBRARIES Qt5::Gui Qt5::Test Qt5::Qml Qt5::Quick KF5::WindowSystem KF5::Plasma KF5::PlasmaQuick) +if(HAVE_X11) + set(dialognativetest_srcs dialognativetest.cpp) + ecm_add_test(${dialognativetest_srcs} TEST_NAME dialognativetest LINK_LIBRARIES Qt5::Gui Qt5::Test Qt5::Qml Qt5::Quick KF5::WindowSystem KF5::Plasma KF5::PlasmaQuick) +endif() set(coronatest_srcs coronatest.cpp) qt5_add_resources(coronatest_srcs coronatestresources.qrc)