Merge pull request #4442 from hummeltech/macOSLCOV

Address `lcov`/`geninfo` errors on macOS CI builds
This commit is contained in:
Artem Pavlenko 2024-04-19 08:57:01 +01:00 committed by GitHub
commit a8d1797bcf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -73,9 +73,12 @@ runs:
if: runner.os != 'Windows' if: runner.os != 'Windows'
shell: "bash" shell: "bash"
run: | run: |
lcov --directory . --capture --output-file coverage.info if [ "$RUNNER_OS" == "macOS" ]; then
lcov --remove coverage.info '/usr/*' '*/vcpkg_installed/*' '/.cache/*' '*/test/*' --output-file coverage.info LCOV_EXTRA_OPTIONS="--ignore-errors gcov --ignore-errors inconsistent --ignore-errors unused"
lcov --list coverage.info fi
lcov ${LCOV_EXTRA_OPTIONS:-} --directory . --capture --output-file coverage.info
lcov ${LCOV_EXTRA_OPTIONS:-} --remove coverage.info '/usr/*' '*/vcpkg_installed/*' '/.cache/*' '*/test/*' --output-file coverage.info
lcov ${LCOV_EXTRA_OPTIONS:-} --list coverage.info
- name: Upload coverage to Codecov (linux & macos) - name: Upload coverage to Codecov (linux & macos)
if: runner.os != 'Windows' if: runner.os != 'Windows'