summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/FileAPI/codemodel-v2.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-08-22 15:40:07 (GMT)
committerBrad King <brad.king@kitware.com>2022-08-22 18:51:16 (GMT)
commit0d64c3abd13a0b14f1a14b7717dbac8988d12256 (patch)
treec925eb0e3a51350002d4e0ca294db5e5f39d431b /Tests/RunCMake/FileAPI/codemodel-v2.cmake
parentef6a4240babe28fdb7f678288aade9f962b7ec11 (diff)
downloadCMake-0d64c3abd13a0b14f1a14b7717dbac8988d12256.zip
CMake-0d64c3abd13a0b14f1a14b7717dbac8988d12256.tar.gz
CMake-0d64c3abd13a0b14f1a14b7717dbac8988d12256.tar.bz2
Tests: Add FileAPI case for cross-directory target_* commands
The backtraces for some of the commands incorrectly come from the target's directory instead of the caller's directory. Expect the incorrect backtraces in test results for now. Increase the minimum required version of CMake in the test case to enable policy CMP0079 to support cross-directory calls. Issue: #23873
Diffstat (limited to 'Tests/RunCMake/FileAPI/codemodel-v2.cmake')
-rw-r--r--Tests/RunCMake/FileAPI/codemodel-v2.cmake3
1 files changed, 3 insertions, 0 deletions
diff --git a/Tests/RunCMake/FileAPI/codemodel-v2.cmake b/Tests/RunCMake/FileAPI/codemodel-v2.cmake
index 019eb87..09db216 100644
--- a/Tests/RunCMake/FileAPI/codemodel-v2.cmake
+++ b/Tests/RunCMake/FileAPI/codemodel-v2.cmake
@@ -14,6 +14,9 @@ add_library(c_static_lib STATIC empty.c)
add_executable(c_static_exe empty.c)
target_link_libraries(c_static_exe PRIVATE c_static_lib)
+add_library(c_subdir STATIC)
+add_subdirectory(subdir)
+
add_subdirectory(cxx)
add_subdirectory(alias)
add_subdirectory(object)