mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-09 21:42:13 +00:00
ed73d130f9
Use LRU modification to hold currently used items. Use RecastMesh binary data for item key. Store original pointer of btCollisionShape in user pointer to make available it as an identifier within all duplicates. Use pointer to heights data array for btHeightfieldTerrainShape.
48 lines
1.5 KiB
CMake
48 lines
1.5 KiB
CMake
find_package(GTest REQUIRED)
|
|
find_package(GMock REQUIRED)
|
|
|
|
if (GTEST_FOUND AND GMOCK_FOUND)
|
|
include_directories(SYSTEM ${GTEST_INCLUDE_DIRS})
|
|
include_directories(SYSTEM ${GMOCK_INCLUDE_DIRS})
|
|
|
|
file(GLOB UNITTEST_SRC_FILES
|
|
../openmw/mwworld/store.cpp
|
|
../openmw/mwworld/esmstore.cpp
|
|
mwworld/test_store.cpp
|
|
|
|
mwdialogue/test_keywordsearch.cpp
|
|
|
|
esm/test_fixed_string.cpp
|
|
|
|
misc/test_stringops.cpp
|
|
|
|
nifloader/testbulletnifloader.cpp
|
|
|
|
detournavigator/navigator.cpp
|
|
detournavigator/settingsutils.cpp
|
|
detournavigator/recastmeshbuilder.cpp
|
|
detournavigator/gettilespositions.cpp
|
|
detournavigator/recastmeshobject.cpp
|
|
detournavigator/navmeshtilescache.cpp
|
|
)
|
|
|
|
source_group(apps\\openmw_test_suite FILES openmw_test_suite.cpp ${UNITTEST_SRC_FILES})
|
|
|
|
find_package(RecastNavigation COMPONENTS DebugUtils Detour Recast REQUIRED)
|
|
|
|
include_directories(SYSTEM ${RecastNavigation_INCLUDE_DIRS})
|
|
|
|
openmw_add_executable(openmw_test_suite openmw_test_suite.cpp ${UNITTEST_SRC_FILES})
|
|
|
|
target_link_libraries(openmw_test_suite ${GMOCK_LIBRARIES} components)
|
|
# Fix for not visible pthreads functions for linker with glibc 2.15
|
|
if (UNIX AND NOT APPLE)
|
|
target_link_libraries(openmw_test_suite ${CMAKE_THREAD_LIBS_INIT})
|
|
endif()
|
|
|
|
if (BUILD_WITH_CODE_COVERAGE)
|
|
add_definitions(--coverage)
|
|
target_link_libraries(openmw_test_suite gcov)
|
|
endif()
|
|
endif()
|