Add test coverage target in Makefile (#16439)

Signed-off-by: zhenshan.cao <zhenshan.cao@zilliz.com>
pull/16341/head
zhenshan.cao 2022-04-11 09:49:34 +08:00 committed by GitHub
parent 994bb829d3
commit 7a3384734a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 3 deletions

View File

@ -148,10 +148,17 @@ build-cpp-embd: pre-proc
build-cpp-with-unittest: pre-proc
@echo "Building Milvus cpp library with unittest ..."
@(env bash $(PWD)/scripts/core_build.sh -t ${mode} -u -c -f "$(CUSTOM_THIRDPARTY_PATH)")
@(env bash $(PWD)/scripts/core_build.sh -t ${mode} -u -f "$(CUSTOM_THIRDPARTY_PATH)")
@(env bash $(PWD)/scripts/cwrapper_build.sh -t ${mode} -f "$(CUSTOM_THIRDPARTY_PATH)")
@(env bash $(PWD)/scripts/cwrapper_rocksdb_build.sh -t ${mode} -f "$(CUSTOM_THIRDPARTY_PATH)")
build-cpp-with-coverage: pre-proc
@echo "Building Milvus cpp library with coverage and unittest ..."
@(env bash $(PWD)/scripts/core_build.sh -t ${mode} -u -c -f "$(CUSTOM_THIRDPARTY_PATH)")
@(env bash $(PWD)/scripts/cwrapper_build.sh -t ${mode} -f "$(CUSTOM_THIRDPARTY_PATH)")
@(env bash $(PWD)/scripts/cwrapper_rocksdb_build.sh -t ${mode} -f "$(CUSTOM_THIRDPARTY_PATH)")
# Run the tests.
unittest: test-cpp test-go
@ -192,12 +199,12 @@ test-cpp: build-cpp-with-unittest
codecov: codecov-go codecov-cpp
# Run codecov-go
codecov-go: build-cpp-with-unittest
codecov-go: build-cpp-with-coverage
@echo "Running go coverage..."
@(env bash $(PWD)/scripts/run_go_codecov.sh)
# Run codecov-cpp
codecov-cpp: build-cpp-with-unittest
codecov-cpp: build-cpp-with-coverage
@echo "Running cpp coverage..."
@(env bash $(PWD)/scripts/run_cpp_codecov.sh)