CMakeLists.txt 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. # Test suite for Standard of Iron
  2. # Uses Google Test framework
  3. # Test executable
  4. add_executable(standard_of_iron_tests
  5. core/serialization_test.cpp
  6. core/ground_type_test.cpp
  7. db/save_storage_test.cpp
  8. db/mission_progress_test.cpp
  9. map/minimap_generator_test.cpp
  10. map/minimap_utils_test.cpp
  11. map/mission_loader_test.cpp
  12. map/campaign_loader_test.cpp
  13. systems/rain_manager_test.cpp
  14. systems/patrol_system_test.cpp
  15. systems/formation_system_test.cpp
  16. systems/guard_system_test.cpp
  17. systems/stamina_system_test.cpp
  18. systems/building_collision_test.cpp
  19. systems/combat_mode_test.cpp
  20. systems/archer_bonus_test.cpp
  21. render/pose_controller_test.cpp
  22. render/pose_controller_compatibility_test.cpp
  23. render/mounted_pose_controller_test.cpp
  24. render/body_frames_test.cpp
  25. render/equipment_registry_test.cpp
  26. render/helmet_renderers_test.cpp
  27. render/armor_renderer_test.cpp
  28. render/horse_animation_controller_test.cpp
  29. render/rider_proportions_test.cpp
  30. render/horse_equipment_renderers_test.cpp
  31. render/spawn_validator_test.cpp
  32. render/battle_render_optimizer_test.cpp
  33. test_main.cpp
  34. )
  35. # Link against GTest, project libraries
  36. target_link_libraries(standard_of_iron_tests
  37. PRIVATE
  38. GTest::gtest
  39. GTest::gmock
  40. Qt${QT_VERSION_MAJOR}::Core
  41. Qt${QT_VERSION_MAJOR}::Gui
  42. Qt${QT_VERSION_MAJOR}::Sql
  43. engine_core
  44. render_gl
  45. game_systems
  46. )
  47. # Include directories
  48. target_include_directories(standard_of_iron_tests
  49. PRIVATE
  50. ${CMAKE_SOURCE_DIR}
  51. ${CMAKE_SOURCE_DIR}/game
  52. )
  53. # Add tests to CTest
  54. include(GoogleTest)
  55. gtest_discover_tests(standard_of_iron_tests)
  56. # Set output directory
  57. set_target_properties(standard_of_iron_tests PROPERTIES
  58. RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin"
  59. )