vcpkg/ports/gtest/usage

7 lines
228 B
Plaintext
Raw Normal View History

The package gtest is compatible with built-in CMake targets:
enable_testing()
find_package(GTest MODULE REQUIRED)
target_link_libraries(main PRIVATE GTest::GTest GTest::Main)
add_test(AllTestsInMain main)