mirror of
https://github.com/cpm-cmake/CPM.cmake.git
synced 2025-11-18 07:07:47 -05:00
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:
14
test/CMakeLists.txt
Normal file
14
test/CMakeLists.txt
Normal 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()
|
||||
Reference in New Issue
Block a user