From c02f8c33ef89178e39c0f697c21d4d2a280e8bfb Mon Sep 17 00:00:00 2001 From: Andy Xu Date: Thu, 31 Aug 2023 06:36:01 -0700 Subject: [PATCH] Enable Coverage Check (#1015) We enable the unit test and short integration test coverage for open PRs. --- script/test/test.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/script/test/test.sh b/script/test/test.sh index bffd728f0..f5009b509 100644 --- a/script/test/test.sh +++ b/script/test/test.sh @@ -54,13 +54,13 @@ check_doc_link() { } unit_test() { - PYTHONPATH="." pytest test/unit_tests/ --durations=20 --cov-report term-missing:skip-covered --cov-config=.coveragerc --cov-context=test --cov=evadb/ --capture=sys --tb=short -v -rsf --log-level=WARNING -m "not benchmark" + PYTHONPATH=./ pytest test/unit_tests/ --durations=20 --cov-report term-missing:skip-covered --cov-config=.coveragerc --cov-context=test --cov=evadb/ --capture=sys --tb=short -v -rsf --log-level=WARNING -m "not benchmark" code=$? print_error_code $code "UNIT TEST" } short_integration_test() { - PYTHONPATH=./ python -m pytest test/integration_tests/short/ -p no:cov -m "not benchmark" + PYTHONPATH=./ pytest test/integration_tests/short/ --durations=20 --cov-report term-missing:skip-covered --cov-config=.coveragerc --cov-context=test --cov=evadb/ --capture=sys --tb=short -v -rsf --log-level=WARNING -m "not benchmark" code=$? print_error_code $code "SHORT INTEGRATION TEST" } @@ -203,8 +203,7 @@ fi ## based on Python version ################################################## -if [[ ( "$PYTHON_VERSION" = "3.10" ) && - ( "$MODE" = "FULL" ) ]]; +if [[ ( "$PYTHON_VERSION" = "3.10" ) ]] then echo "UPLOADING COVERAGE REPORT" coveralls