mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-01-30 17:40:05 +08:00
add the possibility to specify a list of sub-test suffixes in a compact way
This commit is contained in:
parent
6feb1d3c0b
commit
4f1419e9c3
@ -120,9 +120,9 @@ macro(ei_add_test testname)
|
||||
|
||||
file(READ "${testname}.cpp" test_source)
|
||||
set(parts 0)
|
||||
string(REGEX MATCHALL "CALL_SUBTEST_[0-9]+|EIGEN_TEST_PART_[0-9]+"
|
||||
string(REGEX MATCHALL "CALL_SUBTEST_[0-9]+|EIGEN_TEST_PART_[0-9]+|EIGEN_SUFFIXES(;[0-9]+)+"
|
||||
occurences "${test_source}")
|
||||
string(REGEX REPLACE "CALL_SUBTEST_|EIGEN_TEST_PART_" "" suffixes "${occurences}")
|
||||
string(REGEX REPLACE "CALL_SUBTEST_|EIGEN_TEST_PART_|EIGEN_SUFFIXES" "" suffixes "${occurences}")
|
||||
list(REMOVE_DUPLICATES suffixes)
|
||||
if(EIGEN_SPLIT_LARGE_TESTS AND suffixes)
|
||||
add_custom_target(${testname})
|
||||
|
Loading…
Reference in New Issue
Block a user