Use reference parser for tests

This commit is contained in:
2025-08-18 06:27:24 -04:00
parent 9e397d19c9
commit 34b5de1744
7 changed files with 961 additions and 792 deletions

View File

@@ -100,6 +100,7 @@ enable_testing()
# Create shared test data library
add_library(test_data STATIC benchmarks/test_data.cpp)
target_include_directories(test_data PUBLIC benchmarks)
target_link_libraries(test_data simdutf::simdutf)
add_executable(test_arena_allocator tests/test_arena_allocator.cpp
src/arena_allocator.cpp)
@@ -109,10 +110,11 @@ target_include_directories(test_arena_allocator PRIVATE src)
add_executable(
test_commit_request
tests/test_commit_request.cpp src/json_commit_request_parser.cpp
src/nlohmann_reference_parser.cpp src/parser_comparison.cpp
src/arena_allocator.cpp ${CMAKE_BINARY_DIR}/json_tokens.cpp)
add_dependencies(test_commit_request generate_json_tokens)
target_link_libraries(test_commit_request doctest::doctest weaseljson test_data
simdutf::simdutf)
nlohmann_json::nlohmann_json simdutf::simdutf)
target_include_directories(test_commit_request PRIVATE src)
add_executable(bench_arena_allocator benchmarks/bench_arena_allocator.cpp