summaryrefslogtreecommitdiffstats
path: root/Tests/Complex
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-07-22 13:31:56 (GMT)
committerBrad King <brad.king@kitware.com>2014-07-22 13:36:57 (GMT)
commitfb95f820e06eb1933a7d3b71bc46eed4d5d25ee6 (patch)
tree8d5067f34ea5f1d6feeab7f4050720c1ebc84e3d /Tests/Complex
parent23ec3738a0bafd23a9d37fc72e7183e8dc84a4ac (diff)
downloadCMake-fb95f820e06eb1933a7d3b71bc46eed4d5d25ee6.zip
CMake-fb95f820e06eb1933a7d3b71bc46eed4d5d25ee6.tar.gz
CMake-fb95f820e06eb1933a7d3b71bc46eed4d5d25ee6.tar.bz2
Tests: Set policies in 'complex' tests
These tests cover the OLD behavior of some policies. Set them to OLD to avoid warnings in the test output. Leave a comment that explains why this is done here but not recommended in general.
Diffstat (limited to 'Tests/Complex')
-rw-r--r--Tests/Complex/CMakeLists.txt15
1 files changed, 15 insertions, 0 deletions
diff --git a/Tests/Complex/CMakeLists.txt b/Tests/Complex/CMakeLists.txt
index 222250c..5e5eead 100644
--- a/Tests/Complex/CMakeLists.txt
+++ b/Tests/Complex/CMakeLists.txt
@@ -14,6 +14,21 @@ if(POLICY CMP0003)
endif()
endif()
+# It is not recommended to set a policy to OLD, but this test
+# covers the OLD behavior of some policies.
+foreach(p
+ CMP0029
+ CMP0032
+ CMP0033
+ CMP0034
+ CMP0043
+ CMP0050
+ )
+ if(POLICY ${p})
+ cmake_policy(SET ${p} OLD)
+ endif()
+endforeach()
+
# Test building without per-rule echo lines in Makefiles.
set_property(GLOBAL PROPERTY RULE_MESSAGES OFF)