add unit tests and determine version from GIT_TAG (#66)

* add unit tests

* determine package version from git tag. closes #54.

* update readme

* bugfix

* update example

* update gitignore
This commit is contained in:
Lars Melchior
2019-06-22 13:31:32 +02:00
committed by GitHub
parent 1e25367c8c
commit 3d75ed06a3
10 changed files with 113 additions and 11 deletions

14
test/CMakeLists.txt Normal file
View File

@@ -0,0 +1,14 @@
cmake_minimum_required(VERSION 3.14 FATAL_ERROR)
file(GLOB tests "${CMAKE_CURRENT_SOURCE_DIR}/unit/*.cmake")
enable_testing()
foreach(test ${tests})
message(STATUS "adding test: ${test}")
add_test(
NAME ${test}
COMMAND ${CMAKE_COMMAND} -DCPM_PATH=${CMAKE_CURRENT_SOURCE_DIR}/../cmake -P "${test}"
)
endforeach()