Skip to content
Snippets Groups Projects
Commit 0731265e authored by René Fritze's avatar René Fritze
Browse files

adds cmake infrastructure for tests

which is so much simpler than the autofools setup it's not even funny
parent 9d6fc189
No related branches found
No related tags found
No related merge requests found
......@@ -58,9 +58,7 @@ LINK_DIRECTORIES( "/usr/lib" )
FILE( GLOB_RECURSE stuff "stuff/*.hh" )
# ADD_EXECUTABLE(function_test dune/stuff/test/function_test.cc ${stuff} )
# TARGET_LINK_LIBRARIES(function_test ${COMMON_LIBS} )
HEADERCHECK( ${stuff} )
ADD_DEFINITIONS( ${MY_CXX_FLAGS} )
\ No newline at end of file
ADD_DEFINITIONS( ${MY_CXX_FLAGS} )
add_subdirectory(dune)
\ No newline at end of file
add_subdirectory(stuff)
\ No newline at end of file
add_subdirectory(test)
\ No newline at end of file
......@@ -2,3 +2,7 @@ test_validation
*.o
*.gcda
*.gcno
common_color
common_logger
common_parameter_validation
function_expression_2
enable_testing()
file( GLOB_RECURSE test_sources "${CMAKE_CURRENT_SOURCE_DIR}/*.cc" )
foreach( source ${test_sources} )
get_filename_component(testname ${source} NAME_WE)
add_executable( ${testname} ${source} )
add_test( ${testname} ${CMAKE_CURRENT_BINARY_DIR}/${testname} )
endforeach( source )
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment