mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-24 06:51:17 +01:00
cmake: Put test targets in folders
This commit is contained in:
parent
1dd229fac8
commit
9180c87197
@ -81,6 +81,9 @@ include(CheckAndAddFlag)
|
|||||||
include(CheckCCompilerFlag)
|
include(CheckCCompilerFlag)
|
||||||
include(DolphinCompileDefinitions)
|
include(DolphinCompileDefinitions)
|
||||||
|
|
||||||
|
# Enable folders for IDE
|
||||||
|
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||||
|
|
||||||
# Libraries to link
|
# Libraries to link
|
||||||
set(LIBS)
|
set(LIBS)
|
||||||
|
|
||||||
|
@ -13,7 +13,10 @@ macro(add_dolphin_test target srcs)
|
|||||||
# Host_ functions.
|
# Host_ functions.
|
||||||
set(srcs2 ${srcs} ${CMAKE_SOURCE_DIR}/Source/UnitTests/TestUtils/StubHost.cpp)
|
set(srcs2 ${srcs} ${CMAKE_SOURCE_DIR}/Source/UnitTests/TestUtils/StubHost.cpp)
|
||||||
add_executable(Test_${target} EXCLUDE_FROM_ALL ${srcs2})
|
add_executable(Test_${target} EXCLUDE_FROM_ALL ${srcs2})
|
||||||
set_target_properties(Test_${target} PROPERTIES OUTPUT_NAME Tests/${target})
|
set_target_properties(Test_${target} PROPERTIES
|
||||||
|
OUTPUT_NAME Tests/${target}
|
||||||
|
FOLDER Tests
|
||||||
|
)
|
||||||
target_link_libraries(Test_${target} ${LIBS})
|
target_link_libraries(Test_${target} ${LIBS})
|
||||||
add_dependencies(unittests Test_${target})
|
add_dependencies(unittests Test_${target})
|
||||||
add_test(NAME ${target} COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/Tests/${target})
|
add_test(NAME ${target} COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/Tests/${target})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user