blob: c2a94bbbe4c7ca3c45af012c9c558776a5ada2f4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
set(vcFiltersFile "${RunCMake_TEST_BINARY_DIR}/foo.vcxproj.filters")
if(NOT EXISTS "${vcFiltersFile}")
set(RunCMake_TEST_FAILED "Filters file ${vcFiltersFile} does not exist.")
return()
endif()
set(foundFileFilter 0)
set(foundFilter 0)
file(STRINGS "${vcFiltersFile}" lines)
foreach(line IN LISTS lines)
if(line MATCHES "<Filter>CMakeListsSourceGroup</Filter>")
set(rule "${CMAKE_MATCH_1}")
if(foundFileFilter)
set(RunCMake_TEST_FAILED "Multiple files listed with filter for CMakeListsSourceGroup.")
return()
endif()
set(foundFileFilter 1)
endif()
if(line MATCHES "<Filter.*Include=\"CMakeListsSourceGroup\"")
set(rule "${CMAKE_MATCH_1}")
if(foundFilter)
set(RunCMake_TEST_FAILED "Multiple copies of CMakeListsSourceGroup filter listed.")
return()
endif()
set(foundFilter 1)
endif()
endforeach()
if(NOT foundFileFilter)
set(RunCMake_TEST_FAILED "File filter for CMakeListsSourceGroup not found.")
endif()
if(NOT foundFilter)
set(RunCMake_TEST_FAILED "Filter CMakeListsSourceGroup not found.")
endif()
|