Fix string/regexp backslash escapes

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
Gilles Peskine 2022-01-25 23:24:34 +01:00
parent cd55fe02ef
commit a18fb9d9ac

View File

@ -162,7 +162,7 @@ list(REMOVE_DUPLICATES test_suites)
list(SORT test_suites)
foreach(test_suite ${test_suites})
get_filename_component(data_name ${test_suite} NAME)
string(REGEX REPLACE "\.data$" "" data_name "${data_name}")
string(REGEX REPLACE "\\.data\$" "" data_name "${data_name}")
string(REPLACE "test_suite_" "" data_name "${data_name}")
string(REGEX MATCH "[^.]*" function_name "${data_name}")
add_test_suite(${function_name} ${data_name})