blob: 0cbb195200db670ab91e6ec155389b9c089912d8 (
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
34
35
|
file(READ "${RunCMake_TEST_BINARY_DIR}/mytargets.cmake" mytargets)
if("${mytargets}" MATCHES "find_dependency\\(P1")
string(APPEND RunCMake_TEST_FAILED "P1 dependency should not be exported but it is\n")
endif()
if(NOT "${mytargets}" MATCHES "find_dependency\\(P2 REQUIRED \"VERSION\" \"1\\.0\"\\)")
string(APPEND RunCMake_TEST_FAILED "P2 dependency should be exported but it is not\n")
endif()
if(NOT "${mytargets}" MATCHES "find_dependency\\(P3 REQUIRED\\)")
string(APPEND RunCMake_TEST_FAILED "P3 dependency should be exported but it is not\n")
endif()
if(NOT "${mytargets}" MATCHES "find_dependency\\(P4 REQUIRED\\)")
string(APPEND RunCMake_TEST_FAILED "P4 dependency should be exported but it is not\n")
endif()
if("${mytargets}" MATCHES "find_dependency\\(P5")
string(APPEND RunCMake_TEST_FAILED "P5 dependency should not be exported but it is\n")
endif()
if(NOT "${mytargets}" MATCHES "find_dependency\\(P6 REQUIRED\\)")
string(APPEND RunCMake_TEST_FAILED "P6 dependency should be exported but it is not\n")
endif()
if("${mytargets}" MATCHES "find_dependency\\(P7")
string(APPEND RunCMake_TEST_FAILED "P7 dependency should not be exported but it is\n")
endif()
if(NOT "${mytargets}" MATCHES "find_dependency\\(P3[^
]*\\)
find_dependency\\(P2[^
]*\\)
find_dependency\\(P8[^
]*\\)
find_dependency\\(P6[^
]*\\)
find_dependency\\(P9[^
]*\\)
find_dependency\\(P4")
string(APPEND RunCMake_TEST_FAILED "Dependencies are not in the correct order\n")
endif()
|