chore: Check that both gtest and gmock exist for tests.

We used to assume gtest installation includes gmock, but some users may
have only gtest and not gmock.

Fixes #2636.
This commit is contained in:
iphydf 2024-02-03 00:05:01 +00:00
parent 42010660e1
commit 8b05296a78
No known key found for this signature in database
GPG Key ID: 3855DBA2D74403C9

View File

@ -527,7 +527,7 @@ endfunction()
# The actual unit tests follow.
#
if(GTEST_FOUND)
if(TARGET GTest::gtest AND TARGET GTest::gmock)
unit_test(toxav ring_buffer)
unit_test(toxav rtp)
unit_test(toxcore DHT)