From 7bf1e7bc091f999acfffb979e3759e227279a005 Mon Sep 17 00:00:00 2001 From: Sascha Grunert Date: Mon, 7 Mar 2022 09:40:26 +0100 Subject: [PATCH] Fix codecov workflow Signed-off-by: Sascha Grunert --- .github/grcov.yml | 7 +++++++ .github/workflows/test.yml | 30 ++++++++++++++++++------------ .travis.yml | 19 ------------------- 3 files changed, 25 insertions(+), 31 deletions(-) create mode 100644 .github/grcov.yml delete mode 100644 .travis.yml diff --git a/.github/grcov.yml b/.github/grcov.yml new file mode 100644 index 0000000..018c79c --- /dev/null +++ b/.github/grcov.yml @@ -0,0 +1,7 @@ +branch: true +ignore-not-existing: true +llvm: true +filter: covered +output-type: lcov +output-path: ./lcov.info +prefix-dir: /home/user/build/ diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0355f2b..19aa900 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -88,20 +88,26 @@ jobs: - uses: actions/checkout@v2 - uses: actions-rs/toolchain@v1 with: - toolchain: stable + toolchain: nightly override: true - - name: Run cargo-tarpaulin - uses: actions-rs/tarpaulin@v0.1 - with: - version: '0.15.0' - args: '-- --test-threads 1' + - name: Install rustfmt + shell: bash + run: rustup component add rustfmt + - name: Unit tests + uses: actions-rs/cargo@v1 + with: + command: test + args: --no-fail-fast + env: + CARGO_INCREMENTAL: '0' + RUSTFLAGS: '-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests' + RUSTDOCFLAGS: '-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests' + - name: Coverage + uses: actions-rs/grcov@v0.1 + with: + config: .github/grcov.yml - name: Upload to codecov.io - uses: codecov/codecov-action@v1.4.1 - - name: Archive code coverage results - uses: actions/upload-artifact@v1 - with: - name: code-coverage-report - path: cobertura.xml + uses: codecov/codecov-action@v2 doc: runs-on: ubuntu-latest diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 9f9daa5..0000000 --- a/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -dist: trusty -language: rust -os: - - linux - - osx -rust: - - stable - - beta - - nightly -matrix: - allow_failures: - - rust: nightly -script: - - cargo test --features="par_iter" - - cargo test --no-default-features -notifications: - email: - on_success: never