chore: update known blocks #17667
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: Unit tests | |
# Cancel workflow if there is a new change to the branch. | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
on: | |
workflow_dispatch: | |
merge_group: | |
pull_request: | |
branches: | |
- main | |
# This needs to be declared explicitly so that the job is actually | |
# run when moved out of draft. | |
types: [opened, synchronize, reopened, ready_for_review] | |
paths-ignore: | |
- "docs/**" | |
- ".github/workflows/docs-*.yml" | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- "docs/**" | |
- ".github/workflows/docs-*.yml" | |
env: | |
CI: 1 | |
CARGO_INCREMENTAL: 0 | |
CACHE_TIMEOUT_MINUTES: 5 | |
RUSTC_WRAPPER: "sccache" | |
CC: "sccache clang" | |
CXX: "sccache clang++" | |
jobs: | |
tests: | |
runs-on: ubuntu-24.04-arm | |
# Run the job only if the PR is not a draft. | |
# This is done to limit the runner cost. | |
if: github.event.pull_request.draft == false | |
timeout-minutes: 45 | |
steps: | |
- name: Checkout Sources | |
uses: actions/checkout@v5 | |
- name: Setup sccache | |
uses: mozilla-actions/[email protected] | |
timeout-minutes: ${{ fromJSON(env.CACHE_TIMEOUT_MINUTES) }} | |
continue-on-error: true | |
- uses: actions/setup-go@v6 | |
with: | |
go-version-file: "go.work" | |
- name: install nextest | |
uses: taiki-e/install-action@nextest | |
- run: make test | |
tests-release: | |
runs-on: ubuntu-24.04-arm | |
# Run the job only if the PR is not a draft. | |
# This is done to limit the runner cost. | |
if: github.event.pull_request.draft == false | |
steps: | |
# find the nearest S3 space for storing cache files | |
- name: Show IP | |
run: curl ifconfig.me | |
continue-on-error: true | |
- name: Checkout Sources | |
uses: actions/checkout@v5 | |
- uses: actions/cache/restore@v4 | |
with: | |
path: | | |
/home/runner/.cache/forest/test/rpc-snapshots/rpc_test | |
# Broad key + prefix-based restore so the latest rpcsnap-<hash> is picked up. | |
key: rpcsnap- | |
enableCrossOsArchive: true | |
- name: Setup sccache | |
uses: mozilla-actions/[email protected] | |
timeout-minutes: ${{ fromJSON(env.CACHE_TIMEOUT_MINUTES) }} | |
continue-on-error: true | |
- uses: actions/setup-go@v6 | |
with: | |
go-version-file: "go.work" | |
- name: install nextest | |
uses: taiki-e/install-action@nextest | |
- run: make test-release | |
env: | |
# To minimize compile times: https://nnethercote.github.io/perf-book/build-configuration.html#minimizing-compile-times | |
RUSTFLAGS: "-C linker=clang -C link-arg=-fuse-ld=lld" | |
- id: get-cache-hash | |
run: | | |
ls -lhR ~/.cache/forest/test/rpc-snapshots/rpc_test/* | |
echo "hash=$(openssl md5 ~/.cache/forest/test/rpc-snapshots/rpc_test/* | sort | openssl md5 | cut -d ' ' -f 2)" >> $GITHUB_OUTPUT | |
shell: bash | |
- uses: actions/cache/save@v4 | |
with: | |
path: | | |
/home/runner/.cache/forest/test/rpc-snapshots/rpc_test | |
key: rpcsnap-${{ steps.get-cache-hash.outputs.hash }} | |
enableCrossOsArchive: true |