diff --git a/CMakeLists.txt b/CMakeLists.txt index dcf03178f..9cc9693f3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -382,9 +382,12 @@ add_subdirectory(capi) #----------------------------------------------------------------------------- # Tests #----------------------------------------------------------------------------- + +option(BUILD_TESTING "Build the testing tree." ON) + if(PROJECT_IS_TOP_LEVEL) - include(CTest) if(BUILD_TESTING) + enable_testing() add_subdirectory(tests) endif() endif()