From f6f40266ba57ab2df99b897c375f85f0a8a97856 Mon Sep 17 00:00:00 2001 From: Levent Kaya Date: Wed, 5 Nov 2025 22:11:58 +0300 Subject: [feature] basic structure --- tests/CMakeLists.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 tests/CMakeLists.txt (limited to 'tests/CMakeLists.txt') diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt new file mode 100644 index 0000000..67baeda --- /dev/null +++ b/tests/CMakeLists.txt @@ -0,0 +1,20 @@ +# Unit tests for BoltDBG + +# Optionally enable sanitizers for test builds +if(BOLTDBG_ENABLE_ASAN) + add_compile_options(-fsanitize=address -fno-omit-frame-pointer) + add_link_options(-fsanitize=address) +endif() + +# Collect test sources +set(TEST_SOURCES + test_main.cpp + test_logger.cpp +) + +add_executable(boltdbg_tests ${TEST_SOURCES}) +target_include_directories(boltdbg_tests PRIVATE ${CMAKE_SOURCE_DIR}/include) +target_link_libraries(boltdbg_tests PRIVATE libboltdbg) + +# If using CTest (already enabled from top-level) +add_test(NAME boltdbg_tests COMMAND boltdbg_tests) -- cgit v1.2.3