35 lines
818 B
CMake
35 lines
818 B
CMake
Include(FetchContent)
|
|
|
|
FetchContent_Declare(
|
|
Catch2
|
|
GIT_REPOSITORY https://github.com/catchorg/Catch2.git
|
|
GIT_TAG v3.4.0 # or a later release
|
|
)
|
|
|
|
FetchContent_MakeAvailable(Catch2)
|
|
|
|
add_executable(tests builder.cpp
|
|
session.cpp
|
|
record.cpp
|
|
connection_pool.cpp
|
|
query.cpp
|
|
backend_provider.cpp
|
|
connection.cpp
|
|
models/product.hpp
|
|
column_generator.cpp
|
|
column_name_generator.cpp
|
|
value_generator.cpp
|
|
models/category.hpp
|
|
models/supplier.hpp
|
|
models/airplane.hpp
|
|
models/flight.hpp
|
|
models/person.hpp
|
|
AnyTypeToVisitorTest.cpp
|
|
ColumnTest.cpp
|
|
SessionRecordTest.cpp)
|
|
target_link_libraries(tests PRIVATE
|
|
Catch2::Catch2WithMain
|
|
matador
|
|
${CMAKE_DL_LIBS}
|
|
${SQLite3_LIBRARIES})
|
|
target_include_directories(tests PUBLIC $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}>/include) |