summaryrefslogtreecommitdiff
path: root/Tests/RunCMake/set_property/Common.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-09-02 16:38:19 -0400
committerStephen Kelly <steveire@gmail.com>2015-09-11 19:13:25 +0200
commited258d606b87dacc465dad73b04f1c3e270b627c (patch)
tree5935969a60c2903eba9388ef19b7ba350ad5e572 /Tests/RunCMake/set_property/Common.cmake
parentfb45c37160e4f8d839a2c29bce80cae7563cfd3a (diff)
downloadcmake-ed258d606b87dacc465dad73b04f1c3e270b627c.tar.gz
Tests: Cover set_property for buildsystem directory properties
Extend the RunCMake.set_property test with cases covering buildsystem directory properties: * COMPILE_DEFINITIONS * COMPILE_OPTIONS * INCLUDE_DIRECTORIES Also test a non-buildsystem property to document the equivalence in behavior.
Diffstat (limited to 'Tests/RunCMake/set_property/Common.cmake')
-rw-r--r--Tests/RunCMake/set_property/Common.cmake14
1 files changed, 14 insertions, 0 deletions
diff --git a/Tests/RunCMake/set_property/Common.cmake b/Tests/RunCMake/set_property/Common.cmake
index b35948735b..9d5e4f4e81 100644
--- a/Tests/RunCMake/set_property/Common.cmake
+++ b/Tests/RunCMake/set_property/Common.cmake
@@ -12,3 +12,17 @@ macro(test_target_property PROP)
message(STATUS "Target ${PROP} is '${val}'")
set_property(TARGET CustomTarget PROPERTY ${PROP})
endmacro()
+
+macro(test_directory_property PROP)
+ set_property(DIRECTORY PROPERTY ${PROP} x)
+ set_property(DIRECTORY PROPERTY ${PROP})
+ set_property(DIRECTORY APPEND PROPERTY ${PROP})
+ set_property(DIRECTORY PROPERTY ${PROP} a)
+ set_property(DIRECTORY APPEND PROPERTY ${PROP} "")
+ set_property(DIRECTORY APPEND PROPERTY ${PROP} b c)
+ set_property(DIRECTORY APPEND PROPERTY ${PROP})
+ set_property(DIRECTORY APPEND PROPERTY ${PROP} "d;;e")
+ get_property(val DIRECTORY PROPERTY ${PROP})
+ message(STATUS "Directory ${PROP} is '${val}'")
+ set_property(DIRECTORY PROPERTY ${PROP})
+endmacro()