diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..935ba6e --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "lib/catch2"] + path = lib/catch2 + url = https://github.com/catchorg/Catch2.git diff --git a/CMakeLists.txt b/CMakeLists.txt index 41926ef..5b53caf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,3 +1,5 @@ +# Copyright (c) Lysann Tranvouez. All rights reserved. + cmake_minimum_required(VERSION 3.29) project(mach_detours C CXX) @@ -26,3 +28,11 @@ add_executable(mach_detours_sample target_link_libraries(mach_detours_sample PRIVATE mach_detours ) + + +add_subdirectory(lib/catch2) +add_executable(mach_detours_tests + tests/test.cpp) +target_link_libraries(mach_detours_tests + PRIVATE Catch2::Catch2WithMain mach_detours +) diff --git a/lib/catch2 b/lib/catch2 new file mode 160000 index 0000000..b3fb4b9 --- /dev/null +++ b/lib/catch2 @@ -0,0 +1 @@ +Subproject commit b3fb4b9feafcd8d91c5cb510a4775143fdbef02f diff --git a/tests/test.cpp b/tests/test.cpp new file mode 100644 index 0000000..b8e5087 --- /dev/null +++ b/tests/test.cpp @@ -0,0 +1 @@ +// Copyright (c) Lysann Tranvouez. All rights reserved.