Attempt to fix test-build on travis
This commit is contained in:
parent
b5ddc344c4
commit
f90a7c735e
|
@ -58,8 +58,9 @@ target_link_libraries(breakhack
|
|||
|
||||
# TESTS:
|
||||
IF (CHECK_FOUND)
|
||||
find_package(Threads REQUIRED)
|
||||
enable_testing()
|
||||
add_executable(test_util test/check_util src/util)
|
||||
target_link_libraries(test_util ${CHECK_LIBRARIES})
|
||||
target_link_libraries(test_util ${CHECK_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
|
||||
add_test(test_util test_util)
|
||||
ENDIF (CHECK_FOUND)
|
||||
|
|
|
@ -13,9 +13,10 @@ add_library(hashtable hashtable.c)
|
|||
include_directories(${CHECK_INCLUDE_DIR})
|
||||
|
||||
if (CHECK_FOUND)
|
||||
find_package(Threads REQUIRED)
|
||||
enable_testing()
|
||||
add_executable(test_table check_hashtable hashtable)
|
||||
target_compile_options(test_table PRIVATE -pthread)
|
||||
target_link_libraries(test_table ${CHECK_LIBRARIES})
|
||||
target_link_libraries(test_table ${CHECK_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
|
||||
add_test(test_table test_table)
|
||||
endif (CHECK_FOUND)
|
||||
|
|
|
@ -13,9 +13,10 @@ add_library(linkedlist linkedlist.c)
|
|||
include_directories(${CHECK_INCLUDE_DIR})
|
||||
|
||||
if (CHECK_FOUND)
|
||||
find_package(Threads REQUIRED)
|
||||
enable_testing()
|
||||
add_executable(test_list check_linkedlist linkedlist)
|
||||
target_compile_options(test_list PRIVATE -pthread)
|
||||
target_link_libraries(test_list ${CHECK_LIBRARIES})
|
||||
target_link_libraries(test_list ${CHECK_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
|
||||
add_test(test_list test_list)
|
||||
endif (CHECK_FOUND)
|
||||
|
|
Loading…
Reference in New Issue