mirror of
https://github.com/actix/actix-extras.git
synced 2024-11-23 15:51:06 +01:00
ci: coverage via just
This commit is contained in:
parent
032aeb6fdb
commit
2a092a19a8
2
.github/workflows/ci-post-merge.yml
vendored
2
.github/workflows/ci-post-merge.yml
vendored
@ -35,7 +35,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
toolchain: nightly
|
toolchain: nightly
|
||||||
|
|
||||||
- name: Install cargo-hack and cargo-ci-cache-clean
|
- name: Install cargo-hack, cargo-ci-cache-clean
|
||||||
uses: taiki-e/install-action@v2.38.0
|
uses: taiki-e/install-action@v2.38.0
|
||||||
with:
|
with:
|
||||||
tool: cargo-hack,cargo-ci-cache-clean
|
tool: cargo-hack,cargo-ci-cache-clean
|
||||||
|
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -97,7 +97,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
toolchain: ${{ matrix.version.version }}
|
toolchain: ${{ matrix.version.version }}
|
||||||
|
|
||||||
- name: Install cargo-hack and cargo-ci-cache-clean
|
- name: Install cargo-hack, cargo-ci-cache-clean
|
||||||
uses: taiki-e/install-action@v2.38.0
|
uses: taiki-e/install-action@v2.38.0
|
||||||
with:
|
with:
|
||||||
tool: cargo-hack,cargo-ci-cache-clean
|
tool: cargo-hack,cargo-ci-cache-clean
|
||||||
|
2
.github/workflows/coverage.yml
vendored
2
.github/workflows/coverage.yml
vendored
@ -35,7 +35,7 @@ jobs:
|
|||||||
tool: cargo-llvm-cov
|
tool: cargo-llvm-cov
|
||||||
|
|
||||||
- name: Generate code coverage
|
- name: Generate code coverage
|
||||||
run: cargo llvm-cov --workspace --all-features --codecov --output-path codecov.json
|
run: just test-coverage-codecov
|
||||||
|
|
||||||
- name: Upload to Codecov
|
- name: Upload to Codecov
|
||||||
uses: codecov/codecov-action@v4.4.1
|
uses: codecov/codecov-action@v4.4.1
|
||||||
|
16
justfile
16
justfile
@ -40,7 +40,21 @@ test:
|
|||||||
|
|
||||||
# Test workspace code and docs.
|
# Test workspace code and docs.
|
||||||
[group("test")]
|
[group("test")]
|
||||||
test-all: (test) (test-docs)
|
test-all: test test-docs
|
||||||
|
|
||||||
|
# Test workspace and collect coverage info.
|
||||||
|
[private]
|
||||||
|
test-coverage:
|
||||||
|
cargo {{ toolchain }} llvm-cov nextest --no-report --all-features
|
||||||
|
cargo {{ toolchain }} llvm-cov --doc --no-report --all-features
|
||||||
|
|
||||||
|
# Test workspace and generate Codecov report.
|
||||||
|
test-coverage-codecov: test-coverage
|
||||||
|
cargo {{ toolchain }} llvm-cov report --doctests --codecov --output-path=codecov.json
|
||||||
|
|
||||||
|
# Test workspace and generate LCOV report.
|
||||||
|
test-coverage-lcov: test-coverage
|
||||||
|
cargo {{ toolchain }} llvm-cov report --doctests --lcov --output-path=lcov.info
|
||||||
|
|
||||||
# Test workspace docs.
|
# Test workspace docs.
|
||||||
[group("test")]
|
[group("test")]
|
||||||
|
Loading…
Reference in New Issue
Block a user