Use add_test signature where target command gets resolved to binary path

As needed for running tests installed with min. ECM 5.38
parent 36c52121
......@@ -21,7 +21,7 @@ macro(ADD_KDED_TEST testname)
add_dependencies(${testname} kscreen) # make sure the dbus interfaces are generated
target_compile_definitions(${testname} PRIVATE "-DTEST_DATA=\"${CMAKE_CURRENT_SOURCE_DIR}/\"")
target_link_libraries(${testname} Qt5::Test Qt5::DBus Qt5::Gui KF5::Screen)
add_test(kscreen-kded-${testname} ${testname})
add_test(NAME kscreen-kded-${testname} COMMAND ${testname})
ecm_mark_as_test(${testname})
endmacro()
......
......@@ -19,5 +19,5 @@ target_link_libraries(osdtest Qt5::Core
KF5::Declarative
)
add_test(kscreen-kded-osdtest osdtest)
add_test(NAME kscreen-kded-osdtest COMMAND osdtest)
ecm_mark_as_test(osdtest)
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