2021-10-12 21:32:33 +02:00
|
|
|
cmake_minimum_required(VERSION 3.16)
|
|
|
|
|
2021-10-14 21:19:31 +02:00
|
|
|
project(algorithms_test)
|
2021-10-12 21:32:33 +02:00
|
|
|
|
|
|
|
|
2021-10-14 21:19:31 +02:00
|
|
|
# Add new tests here #
|
|
|
|
set(AVAILABLE_TESTS
|
|
|
|
TestSucceeding
|
|
|
|
TestFailing
|
|
|
|
)
|
2021-10-12 21:32:33 +02:00
|
|
|
|
|
|
|
|
2021-10-14 21:19:31 +02:00
|
|
|
add_executable(algorithms_test source/hash.cpp source/main.cpp include/tests.hpp)
|
|
|
|
target_include_directories(algorithms_test PRIVATE include)
|
|
|
|
target_link_libraries(algorithms_test libimhex)
|
|
|
|
|
|
|
|
set_target_properties(algorithms_test PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
|
|
|
|
|
|
|
foreach (test IN LISTS AVAILABLE_TESTS)
|
|
|
|
add_test(NAME "Algorithms/${test}" COMMAND algorithms_test "${test}" WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
|
|
|
endforeach ()
|