diff --git a/cmake/Modules/OpmLibMain.cmake b/cmake/Modules/OpmLibMain.cmake index 5a4d22ec1..4f1a84a7b 100644 --- a/cmake/Modules/OpmLibMain.cmake +++ b/cmake/Modules/OpmLibMain.cmake @@ -242,6 +242,14 @@ macro (cond_disable_test name) endif ((NOT DEFINED HAVE_${name}) OR (NOT HAVE_${name})) endmacro (cond_disable_test name) +# use this target to run all tests +add_custom_target (check + COMMAND ${CMAKE_CTEST_COMMAND} + DEPENDS test-suite + COMMENT "Checking if library is functional" + VERBATIM + ) + # special processing for tests if (COMMAND tests_hook) tests_hook () @@ -253,14 +261,6 @@ if (BUILD_TESTING) opm_compile_satellites (${project} tests "" "${tests_REGEXP}") endif (BUILD_TESTING) -# use this target to run all tests -add_custom_target (check - COMMAND ${CMAKE_CTEST_COMMAND} - DEPENDS test-suite - COMMENT "Checking if library is functional" - VERBATIM - ) - # use this target to check local git commits add_custom_target(check-commits COMMAND ${CMAKE_COMMAND}