docs: add Contract Events table, security review version, and top_up new-token test #142
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: Coverage | |
| # cargo-llvm-cov runs the test suite against the host target, not | |
| # wasm32v1-none — Soroban contract tests already run on the host (see | |
| # test.yml), so no separate wasm coverage build is needed. | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| coverage: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: llvm-tools-preview | |
| - name: Cache cargo registry and build artifacts | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| target | |
| key: ${{ runner.os }}-cargo-coverage-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@cargo-llvm-cov | |
| - name: Generate lcov report | |
| run: cargo llvm-cov --workspace --lcov --output-path lcov.info | |
| - name: Generate HTML report | |
| run: cargo llvm-cov --workspace --html --output-dir coverage-html | |
| - name: Enforce baseline coverage threshold | |
| # Baseline set at 60%: comfortably below what the current suite | |
| # already achieves, so this catches a large regression (e.g. a new | |
| # entry point shipped with no tests at all) without blocking | |
| # unrelated PRs on small, incidental coverage dips. Raise this over | |
| # time as coverage improves. | |
| run: cargo llvm-cov --workspace --fail-under-lines 60 | |
| - name: Upload lcov report | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: lcov-report | |
| path: lcov.info | |
| - name: Upload HTML report | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-html | |
| path: coverage-html |