Skip to content

Commit 07deea2

Browse files
committed
cmake: Fix test name
1 parent 2022631 commit 07deea2

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

unittest/CMakeLists.txt

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,17 @@ function(ADD_LIB_UNIT_TEST test)
88

99
if(BUILD_TESTING)
1010
add_library(${test_target} SHARED "${test}.cpp")
11-
else(BUILD_TESTING)
11+
else()
1212
add_library(${test_target} SHARED EXCLUDE_FROM_ALL "${test}.cpp")
13-
endif(BUILD_TESTING)
13+
endif()
1414
set_standard_output_directory(${test_target})
1515

1616
target_link_libraries(${test_target} PUBLIC ${PROJECT_NAME})
17-
set_target_properties(${test_target} PROPERTIES PREFIX "")
17+
set_target_properties(
18+
${test_target}
19+
PROPERTIES PREFIX ""
20+
LIBRARY_OUTPUT_NAME ${test}
21+
RUNTIME_OUTPUT_NAME ${test})
1822

1923
set_target_properties(${test_target} PROPERTIES SUFFIX ${PYTHON_EXT_SUFFIX})
2024

0 commit comments

Comments
 (0)