diff --git a/Tests/GeneratorExpression/CMakeLists.txt b/Tests/GeneratorExpression/CMakeLists.txt index 891fa11a6..581d4838e 100644 --- a/Tests/GeneratorExpression/CMakeLists.txt +++ b/Tests/GeneratorExpression/CMakeLists.txt @@ -14,6 +14,9 @@ add_custom_target(check ALL -Dtest_and_1=$ -Dtest_and_1_0=$ -Dtest_and_1_1=$ + # Ordinarily, the 'invalidcontent' would cause an error, but + # the '0' makes the AND abort early. + -Dtest_and_0_invalidcontent=$ -Dtest_config_0=$x> -Dtest_config_1=$> -Dtest_not_0=$ @@ -24,6 +27,7 @@ add_custom_target(check ALL -Dtest_or_1=$ -Dtest_or_1_0=$ -Dtest_or_1_1=$ + -Dtest_or_1_invalidcontent=$ -Dtest_bool_notfound=$ -Dtest_bool_foo_notfound=$ -Dtest_bool_true=$ diff --git a/Tests/GeneratorExpression/check.cmake b/Tests/GeneratorExpression/check.cmake index 8ffa4819e..88a60ce74 100644 --- a/Tests/GeneratorExpression/check.cmake +++ b/Tests/GeneratorExpression/check.cmake @@ -15,6 +15,7 @@ check(test_and_0_1 "0") check(test_and_1 "1") check(test_and_1_0 "0") check(test_and_1_1 "1") +check(test_and_0_invalidcontent "0") check(test_config_0 "0") check(test_config_1 "1") check(test_not_0 "1") @@ -25,6 +26,7 @@ check(test_or_0_1 "1") check(test_or_1 "1") check(test_or_1_0 "1") check(test_or_1_1 "1") +check(test_or_1_invalidcontent "1") check(test_bool_notfound "0") check(test_bool_foo_notfound "0") check(test_bool_true "1") diff --git a/Tests/RunCMake/GeneratorExpression/BadAND-stderr.txt b/Tests/RunCMake/GeneratorExpression/BadAND-stderr.txt index 36302db9b..0e48ba423 100644 --- a/Tests/RunCMake/GeneratorExpression/BadAND-stderr.txt +++ b/Tests/RunCMake/GeneratorExpression/BadAND-stderr.txt @@ -39,6 +39,15 @@ CMake Error at BadAND.cmake:1 \(add_custom_target\): \$ + Parameters to \$ must resolve to either '0' or '1'. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at BadAND.cmake:1 \(add_custom_target\): + Error evaluating generator expression: + + \$ + Parameters to \$ must resolve to either '0' or '1'. Call Stack \(most recent call first\): CMakeLists.txt:3 \(include\)$ diff --git a/Tests/RunCMake/GeneratorExpression/BadAND.cmake b/Tests/RunCMake/GeneratorExpression/BadAND.cmake index 265e4149b..8a7993f53 100644 --- a/Tests/RunCMake/GeneratorExpression/BadAND.cmake +++ b/Tests/RunCMake/GeneratorExpression/BadAND.cmake @@ -4,4 +4,5 @@ add_custom_target(check ALL COMMAND check $ $ $ + $ VERBATIM) diff --git a/Tests/RunCMake/GeneratorExpression/BadOR-stderr.txt b/Tests/RunCMake/GeneratorExpression/BadOR-stderr.txt index d4ccab74c..eb263286e 100644 --- a/Tests/RunCMake/GeneratorExpression/BadOR-stderr.txt +++ b/Tests/RunCMake/GeneratorExpression/BadOR-stderr.txt @@ -39,6 +39,15 @@ CMake Error at BadOR.cmake:1 \(add_custom_target\): \$ + Parameters to \$ must resolve to either '0' or '1'. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at BadOR.cmake:1 \(add_custom_target\): + Error evaluating generator expression: + + \$ + Parameters to \$ must resolve to either '0' or '1'. Call Stack \(most recent call first\): CMakeLists.txt:3 \(include\)$ diff --git a/Tests/RunCMake/GeneratorExpression/BadOR.cmake b/Tests/RunCMake/GeneratorExpression/BadOR.cmake index 0813400d6..c0309da25 100644 --- a/Tests/RunCMake/GeneratorExpression/BadOR.cmake +++ b/Tests/RunCMake/GeneratorExpression/BadOR.cmake @@ -4,4 +4,5 @@ add_custom_target(check ALL COMMAND check $ $ $ + $ VERBATIM)