@@ -458,12 +458,13 @@ if(PAIMON_BUILD_TESTS)
458458 test_utils_static
459459 ${GTEST_LINK_TOOLCHAIN} )
460460
461+ set (COMMON_SST_FILE_FORMAT_TEST
462+ common/compression/block_compression_factory_test.cpp
463+ common/sst/sst_file_io_test.cpp common/utils/crc32c_test.cpp)
461464 if (APPLE )
462465 add_paimon_test (common_sst_file_format_test
463466 SOURCES
464- common/compression/block_compression_factory_test.cpp
465- common/sst/sst_file_io_test.cpp
466- common/utils/crc32c_test.cpp
467+ ${COMMON_SST_FILE_FORMAT_TEST}
467468 STATIC_LINK_LIBS
468469 paimon_shared
469470 test_utils_static
@@ -473,9 +474,7 @@ if(PAIMON_BUILD_TESTS)
473474 else ()
474475 add_paimon_test (common_sst_file_format_test
475476 SOURCES
476- common/compression/block_compression_factory_test.cpp
477- common/sst/sst_file_io_test.cpp
478- common/utils/crc32c_test.cpp
477+ ${COMMON_SST_FILE_FORMAT_TEST}
479478 STATIC_LINK_LIBS
480479 paimon_shared
481480 test_utils_static
@@ -619,14 +618,17 @@ if(PAIMON_BUILD_TESTS)
619618 ${TEST_STATIC_LINK_LIBS}
620619 ${GTEST_LINK_TOOLCHAIN} )
621620
621+ set (FS_TEST
622+ common/fs/file_system_test.cpp
623+ common/fs/resolving_file_system_test.cpp
624+ fs/local/local_file_test.cpp
625+ # fs/jindo/jindo_file_system_factory_test.cpp
626+ # fs/jindo/jindo_file_system_test.cpp
627+ )
622628 if (APPLE )
623629 add_paimon_test (fs_test
624630 SOURCES
625- common/fs/file_system_test.cpp
626- common/fs/resolving_file_system_test.cpp
627- fs/local/local_file_test.cpp
628- # fs/jindo/jindo_file_system_factory_test.cpp
629- # fs/jindo/jindo_file_system_test.cpp
631+ ${FS_TEST}
630632 STATIC_LINK_LIBS
631633 paimon_shared
632634 "-Wl,-force_load,$<TARGET_FILE :paimon_local_file_system_static >"
@@ -636,11 +638,7 @@ if(PAIMON_BUILD_TESTS)
636638 else ()
637639 add_paimon_test (fs_test
638640 SOURCES
639- common/fs/file_system_test.cpp
640- common/fs/resolving_file_system_test.cpp
641- fs/local/local_file_test.cpp
642- # fs/jindo/jindo_file_system_factory_test.cpp
643- # fs/jindo/jindo_file_system_test.cpp
641+ ${FS_TEST}
644642 STATIC_LINK_LIBS
645643 paimon_shared
646644 "-Wl,--whole-archive"
0 commit comments