summaryrefslogtreecommitdiffstats
path: root/Tests/FindPackageTest
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-08-07 13:57:22 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-08-07 13:57:35 (GMT)
commitce14f6c67724fccc25547db62e645ab8d115841c (patch)
tree85ab70a5fc02d6cdfe6f7f471e8d11492702395c /Tests/FindPackageTest
parente295290ed707a78a0ba6c66cbd1bbf069b5d582c (diff)
parent8ed868606ddae005b4a50319bdc291b8df5b525a (diff)
downloadCMake-ce14f6c67724fccc25547db62e645ab8d115841c.zip
CMake-ce14f6c67724fccc25547db62e645ab8d115841c.tar.gz
CMake-ce14f6c67724fccc25547db62e645ab8d115841c.tar.bz2
Merge topic 'find_package-prefer-config-not-found'
8ed868606d find_package: Fix prefer-config mode to not fail on missing optional package Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3653
Diffstat (limited to 'Tests/FindPackageTest')
-rw-r--r--Tests/FindPackageTest/CMakeLists.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/Tests/FindPackageTest/CMakeLists.txt b/Tests/FindPackageTest/CMakeLists.txt
index 519608c..7217f43 100644
--- a/Tests/FindPackageTest/CMakeLists.txt
+++ b/Tests/FindPackageTest/CMakeLists.txt
@@ -653,3 +653,9 @@ find_package(ACME NO_MODULE)
if(ACME_FOUND)
message(SEND_ERROR "Should not find ACME package")
endif()
+
+############################################################################
+##Test find_package CMAKE_FIND_PACKAGE_PREFER_CONFIG with unknown package
+
+set(CMAKE_FIND_PACKAGE_PREFER_CONFIG ON)
+find_package(DoesNotExist)