summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CMP0170/CMP0170.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/CMP0170/CMP0170.cmake')
-rw-r--r--Tests/RunCMake/CMP0170/CMP0170.cmake18
1 files changed, 18 insertions, 0 deletions
diff --git a/Tests/RunCMake/CMP0170/CMP0170.cmake b/Tests/RunCMake/CMP0170/CMP0170.cmake
new file mode 100644
index 0000000..4e63e25
--- /dev/null
+++ b/Tests/RunCMake/CMP0170/CMP0170.cmake
@@ -0,0 +1,18 @@
+cmake_policy(SET CMP0168 NEW) # Faster, don't need to test with sub-build
+cmake_policy(SET CMP0169 OLD) # So we can test FetchContent_Populate() directly
+
+set(FETCHCONTENT_FULLY_DISCONNECTED TRUE)
+
+include(FetchContent)
+
+message(STATUS "Starting population")
+
+FetchContent_Declare(t1
+ SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/IdoNotExist"
+)
+FetchContent_Populate(t1)
+
+FetchContent_Declare(t2
+ SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}/IdoNotExist"
+)
+FetchContent_MakeAvailable(t2)