Files
XCEngine/tests/math/CMakeLists.txt

34 lines
826 B
CMake
Raw Normal View History

# ============================================================
# Math Library Tests
# ============================================================
set(MATH_TEST_SOURCES
test_vector.cpp
test_matrix.cpp
test_quaternion.cpp
test_geometry.cpp
)
add_executable(xcengine_math_tests ${MATH_TEST_SOURCES})
# Exclude all static runtime libraries to avoid conflicts
if(MSVC)
set_target_properties(xcengine_math_tests PROPERTIES
LINK_FLAGS "/NODEFAULTLIB:libcpmt.lib /NODEFAULTLIB:libcmt.lib"
)
endif()
target_link_libraries(xcengine_math_tests
PRIVATE
XCEngine
GTest::gtest
GTest::gtest_main
)
target_include_directories(xcengine_math_tests PRIVATE
${CMAKE_SOURCE_DIR}/engine/include
${CMAKE_SOURCE_DIR}/tests/fixtures
)
add_test(NAME MathTests COMMAND xcengine_math_tests)