Skip to content

Commit

Permalink
Disable warnings in gmock
Browse files Browse the repository at this point in the history
  • Loading branch information
dneto0 committed Dec 16, 2024
1 parent fa1ffec commit 7089a8c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -301,15 +301,16 @@ if(CPPDAP_BUILD_TESTS)
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
set(INSTALL_GTEST OFF CACHE BOOL "" FORCE)
add_subdirectory(${CPPDAP_GOOGLETEST_DIR})
# googletest has -Werror=maybe-uninitialized problem.
# googletest has -Werror=maybe-uninitialized problems.
# Disable all warnings in googletest code.
target_compile_options(gtest PRIVATE -w)
# gmock has -Werror=deprecated-copy problems.
target_compile_options(gmock PRIVATE -w)
endif()

add_executable(cppdap-unittests ${DAP_TEST_LIST})
add_test(NAME cppdap-unittests COMMAND cppdap-unittests)

target_include_directories(cppdap-unittests PUBLIC ${DAP_TEST_INCLUDE_DIR} )
set_target_properties(cppdap-unittests PROPERTIES
FOLDER "Tests"
)
Expand Down

0 comments on commit 7089a8c

Please sign in to comment.