Commit ced8f3d4 authored by Laurent Montel's avatar Laurent Montel 😁

Allow to run test without install it

parent fb3c059e
......@@ -4,8 +4,16 @@ if (POLICY CMP0063)
cmake_policy(SET CMP0063 NEW)
endif()
option(RUN_UNINSTALL "test run uninstalled apps (experimental)" FALSE)
set(KF5_VERSION "5.37.0")
find_package(ECM ${KF5_VERSION} REQUIRED NO_MODULE)
set(ECM_VERSION ${KF5_VERSION})
# ECM setup
if (RUN_UNINSTALL)
set(ECM_VERSION "5.38.0")
endif()
find_package(ECM ${ECM_VERSION} REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH})
include(ECMInstallIcons)
......
add_executable( serversievesettingstest serversievesettingstest.cpp)
add_test(serversievesettingstest serversievesettingstest)
add_test(NAME serversievesettingstest COMMAND serversievesettingstest)
ecm_mark_as_test(serversievesettingstest)
target_link_libraries( serversievesettingstest Qt5::Test Qt5::Widgets KF5::MailTransport KF5::I18n KF5::ConfigGui KF5::KSieveUi libsieveeditor)
set( sieveeditorutiltest_source sieveeditorutiltest.cpp )
add_executable( sieveeditorutiltest ${sieveeditorutiltest_source})
add_test(sieveeditorutiltest sieveeditorutiltest)
add_test(NAME sieveeditorutiltest COMMAND sieveeditorutiltest)
ecm_mark_as_test(sieveeditorutiltest)
target_link_libraries( sieveeditorutiltest Qt5::Test KF5::MailTransport KF5::I18n KF5::ConfigGui KF5::KSieveUi libsieveeditor)
......@@ -15,7 +15,7 @@ macro(add_sieveserver_unittest _source _additionalSource)
set(_test ${_source} ${_additionalSource})
get_filename_component(_name ${_source} NAME_WE)
add_executable( ${_name} ${_test} )
add_test( ${_name} ${_name} )
add_test( NAME ${_name} COMMAND ${_name} )
ecm_mark_as_test(sieveserver-${_name})
target_link_libraries( ${_name}
Qt5::Test
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment