cmake: Run make coverage in parallel by default.
[cvc5.git] / test / CMakeLists.txt
1 #-----------------------------------------------------------------------------#
2 # Add subdirectories
3
4 add_subdirectory(regress)
5 add_subdirectory(system EXCLUDE_FROM_ALL)
6
7 if(BUILD_BINDINGS_JAVA)
8 add_subdirectory(java)
9 endif()
10
11 if(ENABLE_UNIT_TESTING)
12 add_subdirectory(unit EXCLUDE_FROM_ALL)
13 endif()
14
15 #-----------------------------------------------------------------------------#
16 # Add target 'check', builds and runs
17 # > unit tests
18 # > regression tests of levels 0 and 1
19 # > system tests
20
21 add_custom_target(check
22 COMMAND
23 ctest --output-on-failure -LE "regress[2-4]" -j${CTEST_NTHREADS} $(ARGS)
24 DEPENDS regress systemtests)
25 if(BUILD_BINDINGS_JAVA)
26 add_dependencies(check cvc4javatests)
27 endif()
28 if(ENABLE_UNIT_TESTING)
29 add_dependencies(check units)
30 endif()