Cmake export tests: Initalize the output variable 'inverted' in macro 'matetestname()'

It could happen that the variable was set in creating a previous test-case.
Some combinations in the controlling files (suspiciousTests, unrelibleTests, ...)
did not set this variable.
This commit is contained in:
Kornel Benko 2016-03-17 00:36:02 +01:00
parent 98883304e2
commit 8e267a7315

View File

@ -114,6 +114,8 @@ function(join rvalues glue routput)
endfunction()
macro(maketestname testname inverted listsuspicious listignored listunreliable listlabels)
# initialize output variable
set(${inverted} 0)
string(REGEX MATCH "\\/[a-z][a-z](_[A-Z][A-Z])?\\/" _v ${${testname}})
if(_v)
string(REGEX REPLACE "\\/" "" _v ${_v})