-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeTests.txt
21 lines (15 loc) · 885 Bytes
/
CMakeTests.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
find_python_module(lit REQUIRED)
include(Valgrind)
find_program(TIME_EXE time)
set(ALL_TESTS tests/)
# it is not possible to use add_dependencies on the install target, since it's
# not a "real" target: https://cmake.org/cmake/help/v3.5/command/add_dependencies.html
# NOTE: if you want to shuffle the tests, add --shuffle
add_custom_target(check
COMMAND ${PYTHON_EXEC} -m lit.main ${ALL_TESTS} -v --time-tests -j 4
COMMENT "running regression test suite..."
USES_TERMINAL
)
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/tests/lit.cfg.in" "${CMAKE_CURRENT_BINARY_DIR}/tests/lit.cfg")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/tests/doc/lit.cfg.in" "${CMAKE_CURRENT_BINARY_DIR}/tests/doc/lit.cfg")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/tests/compare.sh" "${CMAKE_CURRENT_BINARY_DIR}/tests/compare.sh")