feat: analytics accumulator, slippage protection, and invoice phase state machine (#447-#450) #325
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: Test | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: wasm32-unknown-unknown | |
| - name: Cache cargo registry | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| target | |
| key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Run tests | |
| run: cargo test --workspace | |
| - name: Storage key snapshot test | |
| run: cargo test -p split storage_snapshot | |
| fuzz: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install nightly Rust toolchain | |
| uses: dtolnay/rust-toolchain@nightly | |
| - name: Cache cargo registry | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| fuzz/target | |
| key: ${{ runner.os }}-cargo-fuzz-${{ hashFiles('fuzz/Cargo.toml') }} | |
| - name: Install cargo-fuzz | |
| run: cargo install cargo-fuzz | |
| - name: Fuzz create_invoice (60s) | |
| run: cargo fuzz run fuzz_create_invoice -- -max_total_time=60 | |
| - name: Fuzz pay (60s) | |
| run: cargo fuzz run fuzz_pay -- -max_total_time=60 | |
| - name: Fuzz release (60s) | |
| run: cargo fuzz run fuzz_release -- -max_total_time=60 | |
| - name: Fuzz refund (60s) | |
| run: cargo fuzz run fuzz_refund -- -max_total_time=60 | |
| - name: Fuzz sequence (60s) | |
| run: cargo fuzz run fuzz_sequence -- -max_total_time=60 |