summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/DisallowedCommands
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-04-21 18:29:27 (GMT)
committerBrad King <brad.king@kitware.com>2017-04-21 19:04:33 (GMT)
commit4f5bbbeab9bbe7dd3aa3bd9be5d201ed2447bad1 (patch)
tree5b9afb2c7559f9a69137cbdcace548e9540c16bb /Tests/RunCMake/DisallowedCommands
parent294cf948dc37799e1980685afbf1fa585ad5b0fb (diff)
downloadCMake-4f5bbbeab9bbe7dd3aa3bd9be5d201ed2447bad1.zip
CMake-4f5bbbeab9bbe7dd3aa3bd9be5d201ed2447bad1.tar.gz
CMake-4f5bbbeab9bbe7dd3aa3bd9be5d201ed2447bad1.tar.bz2
Add deprecation warnings for policies CMP0036 and below
The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for some policies to encourage projects to port away from setting policies to OLD.
Diffstat (limited to 'Tests/RunCMake/DisallowedCommands')
-rw-r--r--Tests/RunCMake/DisallowedCommands/CMP0029-OLD-stderr.txt10
-rw-r--r--Tests/RunCMake/DisallowedCommands/CMP0030-OLD-stderr.txt13
2 files changed, 22 insertions, 1 deletions
diff --git a/Tests/RunCMake/DisallowedCommands/CMP0029-OLD-stderr.txt b/Tests/RunCMake/DisallowedCommands/CMP0029-OLD-stderr.txt
new file mode 100644
index 0000000..430c865
--- /dev/null
+++ b/Tests/RunCMake/DisallowedCommands/CMP0029-OLD-stderr.txt
@@ -0,0 +1,10 @@
+^CMake Deprecation Warning at CMP0029-OLD.cmake:[0-9]+ \(cmake_policy\):
+ The OLD behavior for policy CMP0029 will be removed from a future version
+ of CMake.
+
+ The cmake-policies\(7\) manual explains that the OLD behaviors of all
+ policies are deprecated and that a policy should be set to OLD only under
+ specific short-term circumstances. Projects should be ported to the NEW
+ behavior and not rely on setting a policy to OLD.
+Call Stack \(most recent call first\):
+ CMakeLists.txt:[0-9]+ \(include\)$
diff --git a/Tests/RunCMake/DisallowedCommands/CMP0030-OLD-stderr.txt b/Tests/RunCMake/DisallowedCommands/CMP0030-OLD-stderr.txt
index e95e16f..d00b827 100644
--- a/Tests/RunCMake/DisallowedCommands/CMP0030-OLD-stderr.txt
+++ b/Tests/RunCMake/DisallowedCommands/CMP0030-OLD-stderr.txt
@@ -1,4 +1,15 @@
-^CMake Error at CMP0030-OLD.cmake:2 \(use_mangled_mesa\):
+^CMake Deprecation Warning at CMP0030-OLD.cmake:[0-9]+ \(cmake_policy\):
+ The OLD behavior for policy CMP0030 will be removed from a future version
+ of CMake.
+
+ The cmake-policies\(7\) manual explains that the OLD behaviors of all
+ policies are deprecated and that a policy should be set to OLD only under
+ specific short-term circumstances. Projects should be ported to the NEW
+ behavior and not rely on setting a policy to OLD.
+Call Stack \(most recent call first\):
+ CMakeLists.txt:[0-9]+ \(include\)
++
+CMake Error at CMP0030-OLD.cmake:2 \(use_mangled_mesa\):
use_mangled_mesa called with incorrect number of arguments
Call Stack \(most recent call first\):
CMakeLists.txt:3 \(include\)$