diff options
author | Brad King <brad.king@kitware.com> | 2020-10-16 13:20:43 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2020-10-16 13:23:42 (GMT) |
commit | b824fd5a2e5e2fa5baa31e4fc11a29b3d446c0d0 (patch) | |
tree | b5f62a4f780f66135d1122ea95df4fef27da72a3 /Tests | |
parent | 284d52eedd3f65d2da3dd18530047dc36c878e58 (diff) | |
parent | 06a9a3bdc3cde5f4bf766771815e95d8e5a8aa62 (diff) | |
download | CMake-b824fd5a2e5e2fa5baa31e4fc11a29b3d446c0d0.zip CMake-b824fd5a2e5e2fa5baa31e4fc11a29b3d446c0d0.tar.gz CMake-b824fd5a2e5e2fa5baa31e4fc11a29b3d446c0d0.tar.bz2 |
Merge topic 'file-configure-angle-brackets'
06a9a3bdc3 file(CONFIGURE): Allow angle brackets in content
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5379
Diffstat (limited to 'Tests')
6 files changed, 8 insertions, 11 deletions
diff --git a/Tests/RunCMake/File_Configure/AngleBracketsContent-stderr.txt b/Tests/RunCMake/File_Configure/AngleBracketsContent-stderr.txt new file mode 100644 index 0000000..08c2ada --- /dev/null +++ b/Tests/RunCMake/File_Configure/AngleBracketsContent-stderr.txt @@ -0,0 +1 @@ +^foo-\$<CONFIG>$ diff --git a/Tests/RunCMake/File_Configure/AngleBracketsContent.cmake b/Tests/RunCMake/File_Configure/AngleBracketsContent.cmake new file mode 100644 index 0000000..04c63bb --- /dev/null +++ b/Tests/RunCMake/File_Configure/AngleBracketsContent.cmake @@ -0,0 +1,6 @@ +file(CONFIGURE + OUTPUT "file.txt" + CONTENT "foo-$<CONFIG>" +) +file(READ ${CMAKE_CURRENT_BINARY_DIR}/file.txt out) +message("${out}") diff --git a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-result.txt b/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-result.txt deleted file mode 100644 index d00491f..0000000 --- a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-result.txt +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-stderr.txt b/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-stderr.txt deleted file mode 100644 index acda654..0000000 --- a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent-stderr.txt +++ /dev/null @@ -1,5 +0,0 @@ -CMake Error at BadArgGeneratorExpressionContent.cmake:[0-9]+ \(file\): - file CONFIGURE called with CONTENT containing a "<". This character is not - allowed. -Call Stack \(most recent call first\): - CMakeLists.txt:3 \(include\) diff --git a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent.cmake b/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent.cmake deleted file mode 100644 index 75fe9e5..0000000 --- a/Tests/RunCMake/File_Configure/BadArgGeneratorExpressionContent.cmake +++ /dev/null @@ -1,4 +0,0 @@ -file(CONFIGURE - OUTPUT "file.txt" - CONTENT "foo-$<CONFIG>" -) diff --git a/Tests/RunCMake/File_Configure/RunCMakeTest.cmake b/Tests/RunCMake/File_Configure/RunCMakeTest.cmake index 0337014..e79de79 100644 --- a/Tests/RunCMake/File_Configure/RunCMakeTest.cmake +++ b/Tests/RunCMake/File_Configure/RunCMakeTest.cmake @@ -1,7 +1,7 @@ include(RunCMake) +run_cmake(AngleBracketsContent) run_cmake(BadArg) -run_cmake(BadArgGeneratorExpressionContent) run_cmake(BadArgGeneratorExpressionOutput) run_cmake(DirOutput) run_cmake(NewLineStyle-NoArg) |