mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Cmake tests: Allow regular expressions to select for reverted tests.
This commit is contained in:
parent
f3a96fb833
commit
dae08c371f
@ -136,19 +136,24 @@ macro(getoutputformats filepath varname)
|
|||||||
set(${varname} ${out_formats})
|
set(${varname} ${out_formats})
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
macro(maketestname testname reverted listreverted listignored)
|
macro(findexpr found testname listname)
|
||||||
set(_idx -1)
|
set(_found 0)
|
||||||
foreach(_itrx ${${listignored}})
|
foreach(_itrx ${${listname}})
|
||||||
set(_itr "^${_itrx}$")
|
set(_itr "^${_itrx}$")
|
||||||
if(${testname} MATCHES ${_itr})
|
if(${testname} MATCHES ${_itr})
|
||||||
set(_idx 0)
|
set(_found 1)
|
||||||
break()
|
break()
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
#list(FIND ${listignored} ${${testname}} _idx)
|
set(${found} ${_found})
|
||||||
if (${_idx} LESS 0)
|
endmacro()
|
||||||
|
|
||||||
|
macro(maketestname testname reverted listreverted listignored)
|
||||||
|
findexpr(mfound ${testname} ${listignored})
|
||||||
|
if (NOT mfound)
|
||||||
|
findexpr(mfound ${testname} ${listreverted})
|
||||||
list(FIND ${listreverted} ${${testname}} _idx)
|
list(FIND ${listreverted} ${${testname}} _idx)
|
||||||
if (${_idx} LESS 0)
|
if (NOT mfound)
|
||||||
set(${reverted} 0)
|
set(${reverted} 0)
|
||||||
else()
|
else()
|
||||||
set(${reverted} 1)
|
set(${reverted} 1)
|
||||||
|
Loading…
Reference in New Issue
Block a user