Skip to content

Commit

Permalink
fix gtest
Browse files Browse the repository at this point in the history
  • Loading branch information
ProphetRu committed Jan 10, 2024
1 parent 0cd8159 commit 2a088d8
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,21 +52,22 @@ target_include_directories(${TEST_NAME}
${GTEST_INCLUDE_DIRS}
)

# link test target against gtest libraries
target_link_libraries(${TEST_NAME}
PRIVATE
${GTEST_BOOTH_LIBRARIES}
gmock
gmock_main
gtest
gtest_main
)

if (MSVC)
# build googletest
add_subdirectory(
${CMAKE_CURRENT_SOURCE_DIR}/googletest
)

# link test target against gtest libraries
target_link_libraries(${TEST_NAME}
PRIVATE
${GTEST_BOOTH_LIBRARIES}
gmock
gmock_main
gtest
gtest_main
)
endif()


Expand Down

0 comments on commit 2a088d8

Please sign in to comment.