Skip to content

Commit c5e34f4

Browse files
committed
Call enable_testing() from root dir
1 parent 26a083b commit c5e34f4

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,5 +30,6 @@ target_link_libraries(scratchcpp PRIVATE zip)
3030
target_compile_definitions(scratchcpp PRIVATE LIBSCRATCHCPP_LIBRARY)
3131

3232
if (LIBSCRATCHCPP_BUILD_UNIT_TESTS)
33+
enable_testing()
3334
add_subdirectory(test)
3435
endif()

test/CMakeLists.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../${GTEST_DIR} ${CMAKE_CURRENT_BIN
1111
# For Windows: Prevent overriding the parent project's compiler/linker settings
1212
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
1313

14-
enable_testing()
15-
1614
include(GoogleTest)
1715
add_subdirectory(zip)
1816
add_subdirectory(load_project)

0 commit comments

Comments
 (0)