diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c692113..b763886 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,13 +46,12 @@ jobs: - name: Install Rust uses: dtolnay/rust-toolchain@master with: - components: 'llvm-tools-preview' toolchain: stable - - name: Install grcov + - name: Install cargo-llvm-cov uses: taiki-e/install-action@main with: - tool: grcov + tool: cargo-llvm-cov - name: Tests if: ${{ !startsWith(matrix.os, 'ubuntu-') }} @@ -69,36 +68,20 @@ jobs: env: CARGO_TERM_COLOR: always GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} - LLVM_PROFILE_FILE: postgresql-%p-%m.profraw RUST_LOG: "info,postgresql_archive=debug,postgresql_commands=debug,postgresql_embedded=debug" RUST_LOG_SPAN_EVENTS: full - RUSTFLAGS: -Cinstrument-coverage - RUSTDOCFLAGS: -Cinstrument-coverage run: | - cargo test --workspace --all-features - - - name: Produce coverage info - if: ${{ startsWith(matrix.os, 'ubuntu-') }} - run: | - grcov $(find . -name "postgresql-*.profraw" -print) \ - -s . \ - --branch \ - --ignore-not-existing \ - --ignore='target/*' \ - --ignore='benches/*' \ - --ignore='/*' \ - --binary-path ./target/debug/ \ - --excl-line='#\[derive' \ - -t lcov \ - -o lcov.info + cargo llvm-cov --all-features --workspace --lcov --output-path lcov.info - name: Upload to codecov.io if: ${{ startsWith(matrix.os, 'ubuntu-') }} - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: files: lcov.info fail_ci_if_error: true - token: ${{ secrets.CODECOV_TOKEN }} + verbose: true + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - name: Install benchmarking tools if: ${{ github.ref == 'refs/heads/main' && startsWith(matrix.os, 'ubuntu-') }}