summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2014-11-12 07:43:17 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2014-11-12 07:43:17 -0800
commit2810f421ae10869f50ee9b95c3260e3d38734306 (patch)
tree3475860ffd4123f3654567c04b3e35341c71cacc /CMakeLists.txt
parent51210a15c3479fccf7c4735f70e0c1a3b6085e8f (diff)
Added cmake test target.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5f1dc25..3dc16a4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -18,6 +18,13 @@ if(UNIX)
INSTALL(FILES man/man1/cmark.1 DESTINATION share/man/man1)
endif(UNIX)
+enable_testing()
+
+# To get verbose output: cmake --build build --target "test" -- ARGS='-V'
+add_test(spectest
+ COMMAND perl "${CMAKE_SOURCE_DIR}/runtests.pl" "${CMAKE_SOURCE_DIR}/spec.txt" "${CMAKE_BINARY_DIR}/src/cmark"
+)
+
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING
"Choose the type of build, options are: Debug Release." FORCE)