Prepare to add fdb implementation

Fixes a end iter deref and remove rpath from test
This commit is contained in:
2024-05-28 13:22:15 -07:00
parent 37f972145e
commit 42298a911a
3 changed files with 18 additions and 13 deletions

View File

@@ -184,14 +184,23 @@ if(BUILD_TESTING)
add_executable(driver TestDriver.cpp FacadeFuzz.cpp)
target_compile_options(driver PRIVATE ${TEST_FLAGS})
target_link_libraries(driver PRIVATE ${PROJECT_NAME})
set_target_properties(driver PROPERTIES SKIP_BUILD_RPATH ON)
if(APPLE)
set(LD_PATH DYLD_LIBRARY_PATH)
else()
set(LD_PATH LD_LIBRARY_PATH)
endif()
foreach(TEST ${CORPUS_TESTS})
get_filename_component(hash ${TEST} NAME)
add_test(NAME versioned_map_blackbox_${hash} COMMAND driver ${TEST})
set_tests_properties(
versioned_map_blackbox_${hash}
PROPERTIES ENVIRONMENT ${LD_PATH}=${CMAKE_BINARY_DIR}/versioned-map)
endforeach()
add_executable(bench Bench.cpp)
target_compile_options(bench PRIVATE ${TEST_FLAGS})
target_link_libraries(bench PRIVATE ${PROJECT_NAME} nanobench)
set_target_properties(bench PROPERTIES SKIP_BUILD_RPATH ON)
# symbol visibility tests
if(NOT CMAKE_BUILD_TYPE STREQUAL Debug)