mirror of
https://github.com/minetest/irrlicht.git
synced 2025-07-03 16:50:27 +02:00
Register Catch2 tests with CTest
This commit is contained in:
@ -309,7 +309,9 @@ if(WIN32)
|
||||
set_target_properties(IrrlichtMt PROPERTIES PREFIX "") # for DLL name
|
||||
endif()
|
||||
|
||||
add_subdirectory(tests)
|
||||
if((CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME) AND BUILD_TESTING)
|
||||
add_subdirectory(tests)
|
||||
endif()
|
||||
|
||||
# Installation of library
|
||||
if(ANDROID)
|
||||
|
@ -18,3 +18,9 @@ target_link_libraries(tests
|
||||
Catch2::Catch
|
||||
IrrlichtMt::IrrlichtMt
|
||||
)
|
||||
|
||||
add_test(
|
||||
NAME tests
|
||||
COMMAND "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/tests"
|
||||
WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
|
||||
)
|
||||
|
Reference in New Issue
Block a user