CMakeLists.txt 388 B

12345678910111213141516
  1. cmake_minimum_required(VERSION 3.0)
  2. project(cmake_test)
  3. # Prepare "Catch" library for other executables
  4. set(CATCH_INCLUDE_DIR Catch2)
  5. add_library(Catch INTERFACE)
  6. target_include_directories(Catch INTERFACE ${CATCH_INCLUDE_DIR})
  7. # Make test executable
  8. set(TEST_SOURCES
  9. Tests/tests.cpp
  10. Tests/Example_test.cpp
  11. )
  12. add_executable(tests ${TEST_SOURCES})
  13. target_link_libraries(tests Catch)