Feat/update #44
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: CI | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| # ---------- rustfmt ---------- | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt | |
| - run: cargo fmt --all -- --check | |
| # ---------- Tests (independent) ---------- | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # Rust toolchain | |
| - uses: dtolnay/rust-toolchain@stable | |
| # --- Pin legacy Noir toolchain (Poseidon2 still in stdlib) ----------- | |
| - name: Install Noir toolchain 1.0.0-beta.3 | |
| uses: noir-lang/noirup@v0.1.2 | |
| with: | |
| toolchain: "1.0.0-beta.3" | |
| # -------------------------------------------------------------------- | |
| # Cache Cargo dependencies | |
| - uses: actions/cache@v3 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| target | |
| key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
| # ---------- Build all Noir circuits ---------- | |
| - name: Generate proofs & VKs | |
| run: tests/build_circuits.sh | |
| # ---------- Run Rust tests ---------- | |
| - name: Run tests | |
| run: cargo test --verbose | |
| # ---------- Test alloc feature ---------- | |
| - name: Test alloc feature | |
| run: cargo test alloc --verbose | |
| # ---------- Test std feature ---------- | |
| - name: Test std feature | |
| run: cargo test std --verbose | |