cmake_minimum_required (VERSION 3.8)

enable_testing()

add_executable(
  AppTest
  MathTest.cpp
)

find_package(GTest CONFIG REQUIRED)
target_link_libraries(AppTest PRIVATE GTest::gtest GTest::gtest_main GTest::gmock GTest::gmock_main)


if (CMAKE_VERSION VERSION_GREATER 3.12)
  set_property(TARGET AppLib PROPERTY CXX_STANDARD 20)
endif()

include(GoogleTest)
gtest_discover_tests(AppTest)

add_test(MathTest AppTest)