Просмотр исходного кода

Enable testing by default

Including CTest defines BUILD_TESTING. It is ON by default.
it also calls enable_testing() if BUILD_TESTING is ON.
Julien Finet лет назад: 13
Родитель
Сommit
8154e4805d
1 измененных файлов с 3 добавлено и 3 удалено
  1. 3 3
      CMakeLists.txt

+ 3 - 3
CMakeLists.txt

@@ -204,11 +204,11 @@ include(CMake/ctkFunctionCompileSnippets.cmake)
 #-----------------------------------------------------------------------------
 # Testing
 #
-option(BUILD_TESTING "Test the project" OFF)
+
+include(CTest)
 mark_as_advanced(BUILD_TESTING)
+
 if(BUILD_TESTING)
-  enable_testing()
-  include(CTest)
   set(CPP_TEST_PATH ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})
   mark_as_advanced(TCL_TCLSH DART_ROOT)