From aecd702ce12696d7ab640b9cf612c1ddc20f8987 Mon Sep 17 00:00:00 2001 From: Sebastian Englbrecht <32066572+herostrat@users.noreply.github.com> Date: Sat, 21 Feb 2026 12:45:15 +0100 Subject: [PATCH] ci: add non-blocking Codecov coverage upload job --- .github/workflows/linux.yml | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 00ca3abd..6ec33f69 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -85,6 +85,43 @@ jobs: cargo test -p geozero --all-features -- --ignored postgis --test-threads 1 env: DATABASE_URL: "${{ steps.pg.outputs.connection-uri }}?sslmode=disable" + + coverage: + name: coverage - stable - x86_64-unknown-linux-gnu + runs-on: ubuntu-latest + continue-on-error: true + permissions: + contents: read + steps: + - name: Checkout + uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 + + - name: Install dependencies + shell: bash + run: | + rustc --version + cargo --version + sudo apt-get update + sudo apt-get install -y libgdal-dev libgeos-dev + + - name: Install protoc + uses: arduino/setup-protoc@149f6c87b92550901b26acd1632e11c3662e381f # v1.3.0 + + - name: Install cargo-llvm-cov + shell: bash + run: cargo install cargo-llvm-cov --locked + + - name: Generate coverage report + shell: bash + run: | + mkdir -p target/llvm-cov + cargo llvm-cov --workspace --all-targets --all-features --include-build-script --codecov --output-path target/llvm-cov/codecov.info + + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v5 + with: + files: target/llvm-cov/codecov.info + fail_ci_if_error: false # This final step is needed to mark the whole workflow as successful # Don't change its name - it is used by the merge protection rules