diff options
author | Andreas Schneider <mail@cynapses.org> | 2010-03-02 13:47:14 +0100 |
---|---|---|
committer | Andreas Schneider <mail@cynapses.org> | 2010-03-02 13:54:14 +0100 |
commit | 464176d5111676161d809ac3f5aeaa0f9fb2ff5b (patch) | |
tree | f9ca2912faa6b68e23603438fc5f13ad19702789 /CMakeLists.txt | |
parent | e8a1d135e21721426851312dc2a9180e5c38273f (diff) | |
download | libssh-464176d5111676161d809ac3f5aeaa0f9fb2ff5b.tar.gz libssh-464176d5111676161d809ac3f5aeaa0f9fb2ff5b.tar.xz libssh-464176d5111676161d809ac3f5aeaa0f9fb2ff5b.zip |
Added unit testing support using check.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index d087366d..ac6a3598 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,6 +37,7 @@ include(MacroCopyFile) # search for libraries find_package(ZLIB REQUIRED) +find_package(Check) if (WITH_GCRYPT) find_package(GCrypt REQUIRED) @@ -75,8 +76,13 @@ install( if (UNIX AND NOT WIN32) add_subdirectory(examples) - endif (UNIX AND NOT WIN32) + +if (CHECK_FOUND AND WITH_TESTING) + include(AddCheckTest) + add_subdirectory(tests) +endif (CHECK_FOUND AND WITH_TESTING) + MESSAGE(STATUS "********************************************") MESSAGE(STATUS "********** ${PROJECT_NAME} build options : **********") if (WITH_LIBZ) |