From 157dc38492f63c819e035e3e34e931181939272b Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Wed, 13 May 2020 10:44:12 +0200 Subject: [PATCH] quick fix(coverage): grcov arg 'output-file' has been renamed to 'output-path' --- .github/workflows/CICD.yml | 2 +- util/show-codecov.BAT | 4 ++-- util/show-codecov.sh | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/CICD.yml b/.github/workflows/CICD.yml index dfecfbce5..efcad13e2 100644 --- a/.github/workflows/CICD.yml +++ b/.github/workflows/CICD.yml @@ -420,7 +420,7 @@ jobs: COVERAGE_REPORT_DIR="target/debug" COVERAGE_REPORT_FILE="${COVERAGE_REPORT_DIR}/lcov.info" mkdir -p "${COVERAGE_REPORT_DIR}" - grcov . --output-type lcov --output-file "${COVERAGE_REPORT_FILE}" --branch ${GRCOV_IGNORE_OPTION} --ignore build.rs --ignore "/*" --ignore "[a-zA-Z]:/*" + grcov . --output-type lcov --output-path "${COVERAGE_REPORT_FILE}" --branch ${GRCOV_IGNORE_OPTION} --ignore build.rs --ignore "/*" --ignore "[a-zA-Z]:/*" echo ::set-output name=report::${COVERAGE_REPORT_FILE} - name: Upload coverage results (to Codecov.io) uses: codecov/codecov-action@v1 diff --git a/util/show-codecov.BAT b/util/show-codecov.BAT index ec8c9deba..224d870b7 100644 --- a/util/show-codecov.BAT +++ b/util/show-codecov.BAT @@ -29,14 +29,14 @@ call rm -r "%COVERAGE_REPORT_DIR%" 2>NUL set GRCOV_IGNORE_OPTION=--ignore build.rs --ignore "/*" --ignore "[A-Za-z]:/*" @rem ::# * build LCOV coverage file -call grcov . --output-type lcov --output-file "%COVERAGE_REPORT_DIR%/../lcov.info" --branch %GRCOV_IGNORE_OPTION% +call grcov . --output-type lcov --output-path "%COVERAGE_REPORT_DIR%/../lcov.info" --branch %GRCOV_IGNORE_OPTION% @rem ::# * build HTML @rem ::# -- use `genhtml` if available for display of additional branch coverage information call genhtml --version 2>NUL 1>&2 if NOT ERRORLEVEL 1 ( call genhtml target/debug/lcov.info --output-directory "%COVERAGE_REPORT_DIR%" --branch-coverage --function-coverage ) else ( - call grcov . --output-type html --output-file "%COVERAGE_REPORT_DIR%" --branch %GRCOV_IGNORE_OPTION% + call grcov . --output-type html --output-path "%COVERAGE_REPORT_DIR%" --branch %GRCOV_IGNORE_OPTION% ) if ERRORLEVEL 1 goto _undefined_ 2>NUL || @for %%G in ("%COMSPEC%") do @title %%nG & @"%COMSPEC%" /d/c exit %ERRORLEVEL% diff --git a/util/show-codecov.sh b/util/show-codecov.sh index f1408caa4..43f93fdea 100755 --- a/util/show-codecov.sh +++ b/util/show-codecov.sh @@ -31,16 +31,16 @@ mkdir -p "${COVERAGE_REPORT_DIR}" export GRCOV_IGNORE_OPTION="--ignore build.rs --ignore \"/*\" --ignore \"[A-Za-z]:/*\"" ## FixME: `grcov . ... ${GRCOV_IGNORE_OPTION}` fails, completely ignoring the contents of ${GRCOV_IGNORE_OPTION} # * build LCOV coverage file -## FixME: grcov . --output-type lcov --output-file "${COVERAGE_REPORT_DIR}/../lcov.info" --branch ${GRCOV_IGNORE_OPTION} -grcov . --output-type lcov --output-file "${COVERAGE_REPORT_DIR}/../lcov.info" --branch --ignore build.rs --ignore '/*' --ignore '[A-Za-z]:/*' +## FixME: grcov . --output-type lcov --output-path "${COVERAGE_REPORT_DIR}/../lcov.info" --branch ${GRCOV_IGNORE_OPTION} +grcov . --output-type lcov --output-path "${COVERAGE_REPORT_DIR}/../lcov.info" --branch --ignore build.rs --ignore '/*' --ignore '[A-Za-z]:/*' # * build HTML # -- use `genhtml` if available for display of additional branch coverage information genhtml --version 2>/dev/null 1>&2 if [ $? -eq 0 ]; then genhtml "${COVERAGE_REPORT_DIR}/../lcov.info" --output-directory "${COVERAGE_REPORT_DIR}" --branch-coverage --function-coverage else - ## FixME: grcov . --output-type html --output-file "${COVERAGE_REPORT_DIR}" --branch ${GRCOV_IGNORE_OPTION} - grcov . --output-type html --output-file "${COVERAGE_REPORT_DIR}" --branch --ignore build.rs --ignore '/*' --ignore '[A-Za-z]:/*' + ## FixME: grcov . --output-type html --output-path "${COVERAGE_REPORT_DIR}" --branch ${GRCOV_IGNORE_OPTION} + grcov . --output-type html --output-path "${COVERAGE_REPORT_DIR}" --branch --ignore build.rs --ignore '/*' --ignore '[A-Za-z]:/*' fi if [ $? -ne 0 ]; then exit 1 ; fi