NAME coverage
EXECUTABLE
ctest -j${CTEST_NTHREADS} -LE "example"
- --output-on-failure $(ARGS) || exit 0)
+ --output-on-failure $(ARGS) || exit 0
+ DEPENDS
+ build-tests)
endif()
if(ENABLE_DEBUG_CONTEXT_MM)
# > regression tests of levels 0 and 1
# > system tests
+add_custom_target(build-tests)
+
# Note: Do not add custom targets for running tests (regress, systemtests,
# units) as dependencies to other run targets. This will result in executing
# tests multiple times. For example, if check would depend on regress it would
# Dependencies of check are added in the corresponding subdirectories.
add_custom_target(check
COMMAND
- ctest --output-on-failure -LE "regress[2-4]" -j${CTEST_NTHREADS} $(ARGS))
+ ctest --output-on-failure -LE "regress[2-4]" -j${CTEST_NTHREADS} $(ARGS)
+ DEPENDS
+ build-tests)
#-----------------------------------------------------------------------------#
# Add subdirectories
OUTPUT_NAME javatests
)
add_dependencies(build-javatests cvc4jar)
-add_dependencies(check build-javatests)
+add_dependencies(build-tests build-javatests)
# Add java tests to ctest
set(classpath "${CMAKE_CURRENT_BINARY_DIR}/javatests.jar")
set(run_regress_script ${CMAKE_CURRENT_LIST_DIR}/run_regression.py)
add_custom_target(build-regress DEPENDS cvc4-bin)
-add_dependencies(check build-regress)
-if(ENABLE_COVERAGE)
- add_dependencies(coverage build-regress)
-endif()
+add_dependencies(build-tests build-regress)
add_custom_target(regress
COMMAND
# > system tests
add_custom_target(build-systemtests)
-add_dependencies(check build-systemtests)
-if(ENABLE_COVERAGE)
- add_dependencies(coverage build-systemtests)
-endif()
+add_dependencies(build-tests build-systemtests)
add_custom_target(systemtests
COMMAND ctest --output-on-failure -L "system" -j${CTEST_NTHREADS} $(ARGS)
# > unit tests
add_custom_target(build-units)
-add_dependencies(check build-units)
-if(ENABLE_COVERAGE)
- add_dependencies(coverage build-units)
-endif()
+add_dependencies(build-tests build-units)
add_custom_target(units
COMMAND ctest --output-on-failure -L "unit" -j${CTEST_NTHREADS} $(ARGS)