aboutsummaryrefslogtreecommitdiff
path: root/tests/ExecuteAllModules
diff options
context:
space:
mode:
authorAlex Merry <alex.merry@kde.org>2014-04-20 15:55:54 +0100
committerAlex Merry <alex.merry@kde.org>2014-04-25 10:43:53 +0100
commiteb8a168c7a184770019d7fcf1dd8ad1a0ba02c80 (patch)
tree361005973f794b22bab8ce0e4a51d8fd47c50e96 /tests/ExecuteAllModules
parentbef4cdd905980b2c8a45a50e2201678c1e4e38af (diff)
downloadextra-cmake-modules-eb8a168c7a184770019d7fcf1dd8ad1a0ba02c80.tar.gz
extra-cmake-modules-eb8a168c7a184770019d7fcf1dd8ad1a0ba02c80.tar.bz2
Split up module execution tests
Find module tests now use find_package(), and there is a version for when CMAKE_MODULE_PATH is set and a version for when ecm_use_find_modules() is used. KDE modules are also now tested. REVIEW 117658
Diffstat (limited to 'tests/ExecuteAllModules')
-rw-r--r--tests/ExecuteAllModules/CMakeLists.txt33
-rw-r--r--tests/ExecuteAllModules/main.c4
2 files changed, 0 insertions, 37 deletions
diff --git a/tests/ExecuteAllModules/CMakeLists.txt b/tests/ExecuteAllModules/CMakeLists.txt
deleted file mode 100644
index 12e86c15..00000000
--- a/tests/ExecuteAllModules/CMakeLists.txt
+++ /dev/null
@@ -1,33 +0,0 @@
-# This file includes all *.cmake files, so they are all executed.
-# As it is it doesn't test a lot.
-# It makes sure that the modules don't contain basic syntax errors.
-# It also makes sure that modules don't fail with an error if something
-# wasn't found but REQUIRED was not given.
-#
-# I guess more things could be added, like checking whether variables are
-# defined after running the modules (e.g. FOO_FOUND etc.).
-project(ExecuteAllModules)
-cmake_minimum_required(VERSION 2.8.12)
-
-file(GLOB all_find_modules "${CMAKE_CURRENT_SOURCE_DIR}/../../find-modules/Find*cmake")
-file(GLOB all_other_modules "${CMAKE_CURRENT_SOURCE_DIR}/../../modules/*cmake")
-
-set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../modules)
-
-foreach(module ${all_find_modules} ${all_other_modules})
- message(STATUS "module: ${module}")
- include("${module}")
-
- # get the "basename" of the package, so the existence of variables like
- # FOO_FOUND could be tested later on, Alex
- string(REGEX REPLACE ".+Find([^\\.]+)\\.cmake" "\\1" packageName "${module}")
- string(TOUPPER "${packageName}" packageNameUpper)
-
-# disabled for now, since too many modules break:
-# if(NOT DEFINED ${packageNameUpper}_FOUND)
-# message(SEND_ERROR "${packageNameUpper}_FOUND not defined !")
-# endif(NOT DEFINED ${packageNameUpper}_FOUND)
-
-endforeach(module ${all_modules})
-
-add_executable(ExecuteAllModules main.c)
diff --git a/tests/ExecuteAllModules/main.c b/tests/ExecuteAllModules/main.c
deleted file mode 100644
index c13815ce..00000000
--- a/tests/ExecuteAllModules/main.c
+++ /dev/null
@@ -1,4 +0,0 @@
-int main()
-{
- return 0;
-}