summaryrefslogtreecommitdiff
path: root/ctest.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'ctest.cmake')
-rw-r--r--ctest.cmake34
1 files changed, 34 insertions, 0 deletions
diff --git a/ctest.cmake b/ctest.cmake
new file mode 100644
index 0000000..1513e87
--- /dev/null
+++ b/ctest.cmake
@@ -0,0 +1,34 @@
+set(CTEST_SOURCE_DIRECTORY /home/adam/Projects/softmotions/ejdb)
+set(CTEST_BINARY_DIRECTORY /home/adam/Projects/softmotions/ejdb/build)
+
+set(CTEST_START_WITH_EMPTY_BINARY_DIRECTORY TRUE)
+set(CTEST_CMAKE_GENERATOR "Unix Makefiles")
+set(CTEST_BUILD_CONFIGURATION "Debug")
+set(CTEST_BUILD_OPTIONS)
+
+set(CTEST_CONFIGURE_COMMAND "${CMAKE_COMMAND} -DCMAKE_BUILD_TYPE:STRING=${CTEST_BUILD_CONFIGURATION}")
+set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} -DBUILD_TESTS:BOOL=ON ${CTEST_BUILD_OPTIONS}")
+set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"-G${CTEST_CMAKE_GENERATOR}\"")
+set(CTEST_CONFIGURE_COMMAND "${CTEST_CONFIGURE_COMMAND} \"${CTEST_SOURCE_DIRECTORY}\"")
+
+find_program(CTEST_COVERAGE_COMMAND NAMES gcov)
+find_program(CTEST_MEMORYCHECK_COMMAND NAMES valgrind)
+
+ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY})
+
+ctest_start("Nightly")
+#ctest_update()
+ctest_configure()
+ctest_build()
+ctest_test()
+
+if (WITH_COVERAGE AND CTEST_COVERAGE_COMMAND)
+ ctest_coverage()
+endif (WITH_COVERAGE AND CTEST_COVERAGE_COMMAND)
+if (WITH_MEMCHECK AND CTEST_MEMORYCHECK_COMMAND)
+ ctest_memcheck()
+endif (WITH_MEMCHECK AND CTEST_MEMORYCHECK_COMMAND)
+
+#ctest_submit()
+
+