diff options
Diffstat (limited to 'Tests/FindPackageTest')
-rw-r--r-- | Tests/FindPackageTest/CMakeLists.txt | 10 | ||||
-rw-r--r-- | Tests/FindPackageTest/FindSomePackage.cmake | 6 | ||||
-rw-r--r-- | Tests/FindPackageTest/FindUpperCasePackage.cmake | 6 |
3 files changed, 22 insertions, 0 deletions
diff --git a/Tests/FindPackageTest/CMakeLists.txt b/Tests/FindPackageTest/CMakeLists.txt index bca149b..a77713f 100644 --- a/Tests/FindPackageTest/CMakeLists.txt +++ b/Tests/FindPackageTest/CMakeLists.txt @@ -43,6 +43,16 @@ if(NOT LOTSOFCOMPONENTS_FOUND) message(SEND_ERROR "LotsOfComponents not found !") endif() +find_package(SomePackage) +if(NOT SomePackage_FOUND) + message(SEND_ERROR "SomePackage with FOUND_VAR SomePackage_FOUND not found !") +endif() + +find_package(UpperCasePackage) +if(NOT UPPERCASEPACKAGE_FOUND) + message(SEND_ERROR "UpperCasePackage with FOUND_VAR UPPERCASEPACKAGE_FOUND not found !") +endif() + #----------------------------------------------------------------------------- # Test system package registry if possible. set(CMakeTestSystemPackage "") diff --git a/Tests/FindPackageTest/FindSomePackage.cmake b/Tests/FindPackageTest/FindSomePackage.cmake new file mode 100644 index 0000000..83d1d0e --- /dev/null +++ b/Tests/FindPackageTest/FindSomePackage.cmake @@ -0,0 +1,6 @@ +set(SOP_FOO TRUE) + +include(FindPackageHandleStandardArgs) + +find_package_handle_standard_args(SomePackage REQUIRED_VARS SOP_FOO + FOUND_VAR SomePackage_FOUND ) diff --git a/Tests/FindPackageTest/FindUpperCasePackage.cmake b/Tests/FindPackageTest/FindUpperCasePackage.cmake new file mode 100644 index 0000000..66c2fea --- /dev/null +++ b/Tests/FindPackageTest/FindUpperCasePackage.cmake @@ -0,0 +1,6 @@ +set(UCP_FOO TRUE) + +include(FindPackageHandleStandardArgs) + +find_package_handle_standard_args(UpperCasePackage REQUIRED_VARS UCP_FOO + FOUND_VAR UPPERCASEPACKAGE_FOUND ) |