2021-04-19 11:16:16 +08:00
|
|
|
# Copyright (C) 2019-2020 Zilliz. All rights reserved.
|
|
|
|
#
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance
|
|
|
|
# with the License. You may obtain a copy of the License at
|
|
|
|
#
|
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software distributed under the License
|
|
|
|
# is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
|
|
|
|
# or implied. See the License for the specific language governing permissions and limitations under the License
|
|
|
|
|
2020-09-15 10:00:00 +08:00
|
|
|
include_directories(${CMAKE_HOME_DIRECTORY}/src)
|
2020-10-27 15:51:16 +08:00
|
|
|
include_directories(${CMAKE_HOME_DIRECTORY}/src/index/knowhere)
|
2021-03-04 17:09:48 +08:00
|
|
|
include_directories(${CMAKE_HOME_DIRECTORY}/src/thirdparty)
|
|
|
|
|
|
|
|
add_definitions(-DMILVUS_TEST_SEGCORE_YAML_PATH="${CMAKE_SOURCE_DIR}/unittest/test_utils/test_segcore.yaml")
|
|
|
|
|
2020-08-27 10:08:42 +08:00
|
|
|
set(MILVUS_TEST_FILES
|
2021-07-13 22:20:33 +08:00
|
|
|
init_gtest.cpp
|
|
|
|
test_binary.cpp
|
|
|
|
test_bitmap.cpp
|
|
|
|
test_common.cpp
|
2020-09-15 10:00:00 +08:00
|
|
|
test_concurrent_vector.cpp
|
|
|
|
test_c_api.cpp
|
2020-11-16 10:55:49 +08:00
|
|
|
test_expr.cpp
|
2021-07-13 22:20:33 +08:00
|
|
|
test_get_entity_by_ids.cpp
|
|
|
|
test_indexing.cpp
|
2020-12-25 11:10:31 +08:00
|
|
|
test_index_wrapper.cpp
|
2021-07-13 22:20:33 +08:00
|
|
|
test_init.cpp
|
2021-04-29 16:48:06 +08:00
|
|
|
test_plan_proto.cpp
|
2021-07-13 22:20:33 +08:00
|
|
|
test_query.cpp
|
|
|
|
test_reduce.cpp
|
|
|
|
test_sealed.cpp
|
|
|
|
test_segcore.cpp
|
|
|
|
test_span.cpp
|
2021-06-19 17:38:11 +08:00
|
|
|
test_timestamp_index.cpp
|
2021-07-20 14:38:11 +08:00
|
|
|
test_reduce_c.cpp
|
2021-11-11 20:42:44 +08:00
|
|
|
test_conf_adapter_mgr.cpp
|
2021-11-16 19:11:10 +08:00
|
|
|
test_similarity_corelation.cpp
|
2021-11-23 10:13:14 +08:00
|
|
|
test_utils.cpp
|
2020-11-30 22:14:19 +08:00
|
|
|
)
|
2021-03-04 17:09:48 +08:00
|
|
|
|
2020-09-15 10:00:00 +08:00
|
|
|
add_executable(all_tests
|
|
|
|
${MILVUS_TEST_FILES}
|
|
|
|
)
|
2020-08-27 10:08:42 +08:00
|
|
|
|
2021-02-22 18:33:40 +08:00
|
|
|
# check if memory leak exists in index builder
|
2021-02-23 14:35:00 +08:00
|
|
|
set(INDEX_BUILDER_TEST_FILES
|
2021-03-04 17:09:48 +08:00
|
|
|
test_index_wrapper.cpp
|
|
|
|
)
|
|
|
|
|
2021-02-23 14:35:00 +08:00
|
|
|
add_executable(index_builder_test
|
|
|
|
${INDEX_BUILDER_TEST_FILES}
|
|
|
|
)
|
2021-05-28 10:39:30 +08:00
|
|
|
|
2021-02-23 14:35:00 +08:00
|
|
|
target_link_libraries(index_builder_test
|
|
|
|
gtest
|
|
|
|
gtest_main
|
|
|
|
milvus_segcore
|
|
|
|
milvus_indexbuilder
|
|
|
|
log
|
|
|
|
pthread
|
|
|
|
)
|
2021-02-20 10:14:03 +08:00
|
|
|
|
2020-09-15 10:00:00 +08:00
|
|
|
target_link_libraries(all_tests
|
|
|
|
gtest
|
2020-10-31 15:11:47 +08:00
|
|
|
milvus_segcore
|
2020-12-25 11:10:31 +08:00
|
|
|
milvus_indexbuilder
|
2020-09-15 10:00:00 +08:00
|
|
|
log
|
|
|
|
pthread
|
2020-10-15 21:31:50 +08:00
|
|
|
)
|
2020-12-09 09:55:56 +08:00
|
|
|
|
2021-05-28 10:39:30 +08:00
|
|
|
install(TARGETS all_tests DESTINATION unittest)
|
|
|
|
install(TARGETS index_builder_test DESTINATION unittest)
|
2021-12-07 20:17:03 +08:00
|
|
|
|