summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@crascit.com>2019-07-01 11:41:24 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-07-01 11:42:04 (GMT)
commit56f5310112705c00e0e1ae876cfde633c04bd740 (patch)
tree6731cd27c366c3ab26abe3e74e10857128d3e5d1 /Tests/RunCMake
parent477a1ae478633a74c4dfe431a0c1e6b51194013b (diff)
parent822abf1265eacdffee37d3ed55e41425b6602e27 (diff)
downloadCMake-56f5310112705c00e0e1ae876cfde633c04bd740.zip
CMake-56f5310112705c00e0e1ae876cfde633c04bd740.tar.gz
CMake-56f5310112705c00e0e1ae876cfde633c04bd740.tar.bz2
Merge topic 'bug/19436'
822abf1265 list(POP_FRONT): Fix always assigning first item to output vars Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3497
Diffstat (limited to 'Tests/RunCMake')
-rw-r--r--Tests/RunCMake/list/POP_FRONT.cmake13
1 files changed, 13 insertions, 0 deletions
diff --git a/Tests/RunCMake/list/POP_FRONT.cmake b/Tests/RunCMake/list/POP_FRONT.cmake
index a2f8f3c..70f757a 100644
--- a/Tests/RunCMake/list/POP_FRONT.cmake
+++ b/Tests/RunCMake/list/POP_FRONT.cmake
@@ -77,3 +77,16 @@ endif()
if(NOT test STREQUAL "two")
message(FATAL_ERROR "`test` has unexpected value `${test}`")
endif()
+
+# BUG 19436
+set(myList a b c)
+list(POP_FRONT myList first second)
+if(NOT first STREQUAL "a")
+ message(FATAL_ERROR "BUG#19436: `first` has unexpected value `${first}`")
+endif()
+if(NOT second STREQUAL "b")
+ message(FATAL_ERROR "BUG#19436: `second` has unexpected value `${second}`")
+endif()
+if(NOT myList STREQUAL "c")
+ message(FATAL_ERROR "BUG#19436: `myList` has unexpected value `${myList}`")
+endif()