diff --git a/CMakeLists.txt b/CMakeLists.txt index 41b4385..0e36efe 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,3 +7,5 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.6) SET(CMAKE_INSTALL_PREFIX "/usr/local") ADD_SUBDIRECTORY (src) +ADD_SUBDIRECTORY (t) +SET_PROPERTY(DIRECTORY "t" PROPERTY COMPILE_FLAGS "-g;-ggdb;-Wall;-Wextra;-pedantic;-O0") diff --git a/t/CMakeLists.txt b/t/CMakeLists.txt new file mode 100644 index 0000000..ad2e4ce --- /dev/null +++ b/t/CMakeLists.txt @@ -0,0 +1,7 @@ +enable_testing() + +set(SRC_DIR "../src") + +add_executable("t_logfile" "t_logfile.c" "${SRC_DIR}/logfile.c") + +add_test("tests/f2b_logfile_*" "t_logfile") diff --git a/t/t_logfile.c b/t/t_logfile.c new file mode 100644 index 0000000..11852bb --- /dev/null +++ b/t/t_logfile.c @@ -0,0 +1,8 @@ +#include + +#include "../src/common.h" +#include "../src/logfile.h" + +int main() { + exit(0); +}