26 lines
677 B
CMake
26 lines
677 B
CMake
add_executable(
|
|
hdk-sdl-tests
|
|
main.cpp
|
|
CoreBindings_test.cpp
|
|
Event_test.cpp
|
|
Properties_test.cpp
|
|
RenderTexture_test.cpp
|
|
VideoBindings_test.cpp
|
|
Window_test.cpp
|
|
Surface_test.cpp
|
|
)
|
|
|
|
if(HDK_COVERAGE)
|
|
target_sources(hdk-sdl-tests PRIVATE CoverageHeaderAggregation.cpp)
|
|
endif()
|
|
|
|
target_link_libraries(hdk-sdl-tests PRIVATE hdk-sdl doctest::doctest)
|
|
target_compile_features(hdk-sdl-tests PRIVATE cxx_std_17)
|
|
|
|
if(HDK_COVERAGE AND TARGET hdk-coverage-flags)
|
|
target_link_libraries(hdk-sdl-tests PRIVATE hdk-coverage-flags)
|
|
endif()
|
|
|
|
add_test(NAME hdk-sdl-tests COMMAND hdk-sdl-tests)
|
|
set_tests_properties(hdk-sdl-tests PROPERTIES ENVIRONMENT "SDL_VIDEODRIVER=dummy")
|