kwin/autotests/tabbox/CMakeLists.txt
Vlad Zahorodnii 4a1e7df599 tabbox: Drop desktop switching
Tabbox supports two operation modes: switching between windows and
desktops. Switching between windows is more commonly used. Desktop
switching is not exposed in user settings and it requires some advanced
knowledge of kwin's internals to enable it.

On the other hand, over the past years, we've double downed on effects
like desktop grid and overview to provide graphical means to switch
between virtual desktops.

This change drops desktop switching because it's effectively unused to
simplify the tabbox code, which can be very handy for the future
refactorings of window switching.
2023-03-24 22:01:12 +00:00

80 lines
2.3 KiB
CMake

add_definitions(-DKWIN_UNIT_TEST)
########################################################
# Test TabBox::ClientModel
########################################################
set(testTabBoxClientModel_SRCS
../../src/tabbox/clientmodel.cpp
../../src/tabbox/tabbox_logging.cpp
../../src/tabbox/tabboxconfig.cpp
../../src/tabbox/tabboxhandler.cpp
mock_tabboxclient.cpp
mock_tabboxhandler.cpp
test_tabbox_clientmodel.cpp
)
add_executable(testTabBoxClientModel ${testTabBoxClientModel_SRCS})
set_target_properties(testTabBoxClientModel PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW")
target_link_libraries(testTabBoxClientModel
Qt::Core
Qt::DBus
Qt::Quick
Qt::Test
Qt::Widgets
Qt::GuiPrivate
KF6::ConfigCore
KF6::I18n
KF6::Package
KF6::WindowSystem
XCB::XCB
)
add_test(NAME kwin-testTabBoxClientModel COMMAND testTabBoxClientModel)
ecm_mark_as_test(testTabBoxClientModel)
########################################################
# Test TabBox::TabBoxHandler
########################################################
set(testTabBoxHandler_SRCS
../../src/tabbox/clientmodel.cpp
../../src/tabbox/tabbox_logging.cpp
../../src/tabbox/tabboxconfig.cpp
../../src/tabbox/tabboxhandler.cpp
mock_tabboxclient.cpp
mock_tabboxhandler.cpp
test_tabbox_handler.cpp
)
add_executable(testTabBoxHandler ${testTabBoxHandler_SRCS})
set_target_properties(testTabBoxHandler PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW")
target_link_libraries(testTabBoxHandler
Qt::Core
Qt::DBus
Qt::Quick
Qt::Test
Qt::Widgets
Qt::GuiPrivate
KF6::ConfigCore
KF6::I18n
KF6::Package
KF6::WindowSystem
XCB::XCB
)
add_test(NAME kwin-testTabBoxHandler COMMAND testTabBoxHandler)
ecm_mark_as_test(testTabBoxHandler)
########################################################
# Test TabBox::TabBoxConfig
########################################################
set(testTabBoxConfig_SRCS
../../src/tabbox/tabbox_logging.cpp
../../src/tabbox/tabboxconfig.cpp
test_tabbox_config.cpp
)
add_executable(testTabBoxConfig ${testTabBoxConfig_SRCS})
target_link_libraries(testTabBoxConfig Qt::Core Qt::Test)
add_test(NAME kwin-testTabBoxConfig COMMAND testTabBoxConfig)
ecm_mark_as_test(testTabBoxConfig)