CMakeLists.txt 510 B

123456789101112131415161718
  1. # do not build the firmware by default (tests are the focus if not crosscompiling)
  2. project(cmake_test)
  3. # include catch_discover_tests function from Catch2
  4. include(${Catch2_SOURCE_DIR}/extras/Catch.cmake)
  5. # Make test executable
  6. set(TEST_SOURCES
  7. Example_test.cpp
  8. PrusaStatistics_test.cpp
  9. #Tests/Timer_test.cpp
  10. #Firmware/Timer.cpp
  11. )
  12. add_executable(tests ${TEST_SOURCES})
  13. target_include_directories(tests PRIVATE tests)
  14. target_link_libraries(tests Catch2::Catch2WithMain)
  15. catch_discover_tests(tests)