Refactor indexer to improve example_crates interface
#59
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Code Coverage | |
| on: [push, pull_request] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| permissions: {} | |
| jobs: | |
| coverage: | |
| name: Code Coverage | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| - name: Install lcov tools | |
| run: sudo apt-get install lcov -y | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@v1 | |
| with: | |
| toolchain: nightly | |
| components: llvm-tools-preview | |
| - name: Rust Cache | |
| uses: Swatinem/[email protected] | |
| - name: Install cargo-llvm-cov | |
| run: if [[ ! -e ~/.cargo/bin/cargo-llvm-cov ]]; then cargo install cargo-llvm-cov; fi | |
| - name: Make coverage directory | |
| run: mkdir coverage | |
| - name: Test and report coverage | |
| run: cargo +nightly llvm-cov -q --doctests --branch --all --exclude sp_fuzz --ignore-filename-regex "example-crates/*" --all-features --lcov --output-path ./coverage/lcov.info | |
| - name: Generate HTML coverage report | |
| run: genhtml -o coverage-report.html --ignore-errors unmapped ./coverage/lcov.info | |
| - name: Coveralls upload | |
| uses: coverallsapp/github-action@master | |
| with: | |
| github-token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-report | |
| path: coverage-report.html |