Skip to content

Commit

Permalink
modify gtest
Browse files Browse the repository at this point in the history
  • Loading branch information
k-yoshimi committed Oct 29, 2018
1 parent 82c37a0 commit f642fb9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 30 deletions.
28 changes: 0 additions & 28 deletions cmake/EnableGtests.cmake

This file was deleted.

13 changes: 11 additions & 2 deletions test/c++/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
cmake_minimum_required(VERSION 2.8.12)
include(EnableGtests) #defined in ./cmake
function(add_gtest test)
set(source "${ARGV1}/${test}.cpp")
set(gtest_src "${ARGV1}/gtest_main.cc;${ARGV1}/gtest-all.cc")

add_executable(${test} ${source} ${gtest_src} ${header_files})
target_link_libraries(${test} ${LINK_ALL})
target_include_directories(${test} PRIVATE ${HDF5_INCLUDE_DIRS})
add_test(NAME ${test} COMMAND ${test} ${test_xml_output})
endfunction(add_gtest)

include_directories(../../c++/include)
include_directories(./)

Expand All @@ -13,7 +22,7 @@ test_pade
)

foreach(test_c++ ${unittest_src_gf})
add_gtest(${test_c++})
add_gtest(${test_c++} ".")
target_link_libraries(${test_c++} gf)
endforeach(test_c++)

Expand Down

0 comments on commit f642fb9

Please sign in to comment.