Try-Runtime Local Test #26
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: Try-Runtime Local Test | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| # Run weekly on Sundays at 2 AM UTC | |
| - cron: '0 2 * * 0' | |
| jobs: | |
| try-runtime-local: | |
| name: Try-Runtime Local Test | |
| runs-on: ubuntu-24.04 | |
| timeout-minutes: 60 | |
| continue-on-error: true | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install linux dependencies | |
| run: sudo apt update && sudo apt install -y cargo clang libssl-dev llvm libudev-dev protobuf-compiler | |
| - name: Install toolchain and rust-src | |
| uses: actions-rs/toolchain@v1 | |
| with: | |
| toolchain: 1.90.0 | |
| override: true | |
| target: wasm32-unknown-unknown | |
| components: rust-src | |
| - name: Enhanced Rust Cache | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| shared-key: "runtime-build" | |
| cache-on-failure: true | |
| - name: Configure Git | |
| run: git config --global url."https://${{ secrets.GH_READ_TOKEN }}:x-oauth-basic@github.com/".insteadOf "https://github.com/" | |
| - name: Install try-runtime | |
| run: cargo install --git https://github.com/paritytech/try-runtime-cli --tag v0.8.0 --locked | |
| - name: Build for try-runtime | |
| run: | | |
| CARGO_INCREMENTAL=1 cargo build --release --features try-runtime | |
| # Test with local node instead of external network | |
| - name: Start local test node | |
| run: | | |
| ./target/release/cere --dev --tmp & | |
| sleep 10 | |
| - name: Check Try-Runtime (Local) | |
| run: | | |
| # Test against local node - much faster and more reliable | |
| try-runtime --runtime ./target/release/wbuild/cere-runtime/cere_runtime.compact.compressed.wasm \ | |
| on-runtime-upgrade --disable-idempotency-checks \ | |
| snap --path /tmp/snap | |
| continue-on-error: true |