CliRunner: - --batch / --config <file> flags trigger batch mode with directory scanning - collect_files() with recursive support and case-insensitive extension matching - build_pipeline() respects AppConfig conversion flags (invert toggle) - Progress output to stderr: "[1/42] Processing DSC09246.ARW..." Tests (test_pipeline.cpp): - AppConfig: load/save roundtrip, missing file error, extension parsing, format mapping, write_default - CropProcessor: levels adjustment, sharpening no-clip, empty image error - ColorCorrector: AWB preserves neutral grey, skips B&W film - Inverter: color negative changes values, B&W inversion, positive passthrough - Preprocessor: 8-bit→16-bit conversion test_rawloader.cpp: added missing <fstream> include Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
48 lines
1.4 KiB
CMake
48 lines
1.4 KiB
CMake
find_package(GTest REQUIRED)
|
|
|
|
# ──────────────────────────────────────────────
|
|
# Pipeline unit tests
|
|
# ──────────────────────────────────────────────
|
|
add_executable(test_pipeline
|
|
test_pipeline.cpp
|
|
)
|
|
|
|
target_link_libraries(test_pipeline PRIVATE
|
|
converter_core
|
|
GTest::gtest
|
|
GTest::gtest_main
|
|
)
|
|
|
|
target_include_directories(test_pipeline PRIVATE
|
|
${CMAKE_SOURCE_DIR}/src
|
|
)
|
|
|
|
target_compile_definitions(test_pipeline PRIVATE
|
|
TEST_DATA_DIR="${CMAKE_SOURCE_DIR}/import"
|
|
)
|
|
|
|
add_test(NAME PipelineTests COMMAND test_pipeline)
|
|
|
|
# ──────────────────────────────────────────────
|
|
# RawLoader integration tests
|
|
# ──────────────────────────────────────────────
|
|
add_executable(test_rawloader
|
|
test_rawloader.cpp
|
|
)
|
|
|
|
target_link_libraries(test_rawloader PRIVATE
|
|
converter_core
|
|
GTest::gtest
|
|
GTest::gtest_main
|
|
)
|
|
|
|
target_include_directories(test_rawloader PRIVATE
|
|
${CMAKE_SOURCE_DIR}/src
|
|
)
|
|
|
|
target_compile_definitions(test_rawloader PRIVATE
|
|
TEST_DATA_DIR="${CMAKE_SOURCE_DIR}/import"
|
|
)
|
|
|
|
add_test(NAME RawLoaderTests COMMAND test_rawloader)
|