File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed
Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -399,6 +399,7 @@ jobs:
399399 run : |
400400 set -e
401401 cd ${DEEPLINK_PATH}/${GITHUB_RUN_NUMBER} && rm -rf ${BUILD_TEST1} && cp -R source ${BUILD_TEST1} && cd ${BUILD_TEST1}
402+ export USE_COVERAGE=ON
402403 export DIOPI_BUILD_TESTRT=ON
403404 cd impl && mkdir lib
404405 cp -R /home/deeplink/*.so lib/
@@ -419,6 +420,15 @@ jobs:
419420 ln -sf /mnt/cache/share/deeplinkci/data/inputs ./cache/diopi && ln -sf /mnt/cache/share/deeplinkci/data/outputs ./cache/diopi && ln -sf /mnt/cache/share/deeplinkci/data/diopi_case_items.cfg ./cache/diopi
420421 python main.py --mode gen_case --impl_folder ${DEEPLINK_PATH}/${GITHUB_RUN_NUMBER}/${BUILD_TEST1}/impl/topsrider/
421422 python main.py --mode run_test
423+ if [ "${ALL_COVERAGE}" = "ON" ]; then
424+ bash /mnt/cache/share/platform/dep/sonar/coverage_DIOPI.sh ${DEEPLINK_PATH}/${GITHUB_RUN_NUMBER}/${BUILD_TEST1} || echo "get coverage fail"
425+ fi
426+ - name : increment coverage check
427+ if : ${{ contains( github.event_name, 'pull_request' ) && contains( github.base_ref, 'main' ) }}
428+ run : |
429+ set -e
430+ cd ${DEEPLINK_PATH}/${GITHUB_RUN_NUMBER}/${BUILD_TEST1}
431+ bash scripts/increment_coverage.sh ${REQUIRE_COVERAGE}
422432
423433 # Rt-Test-Topsrider:
424434 # name: Rt-Test-Topsrider
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ case $1 in
1212 mkdir -p build && cd build
1313 # do not use && between cmake and make -j, because the cmake error will not incur error exit (return code is 0) in switch case statementts.
1414 cmake -DPYTHON_EXECUTABLE=$( python3 -c " import sys; print(sys.executable)" ) .. -DIMPL_OPT=tops -DTEST=ON -DCMAKE_BUILD_TYPE=Debug \
15- -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DTOPS_HOME=/home/cse/src/install/usr
15+ -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DTOPS_HOME=/home/cse/src/install/usr -DENABLE_COVERAGE= ${USE_COVERAGE}
1616 make -j8
1717 ;;
1818 clean)
You can’t perform that action at this time.
0 commit comments