ci: use self-hosted runner in scheduled task #4368
Workflow file for this run
This file contains 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
--- | |
on: | |
push: | |
branches: | |
- master | |
- develop | |
pull_request: | |
name: Tests | |
jobs: | |
test: | |
name: Test suite ${{ matrix.profile }} | |
runs-on: github-hosted-heavy-runner | |
strategy: | |
fail-fast: false | |
matrix: | |
profile: [ mainnet, testnet, mainnet-silo, testnet-silo ] | |
steps: | |
- name: Potential broken submodules fix | |
run: | | |
git checkout -f $(git -c user.name=x -c user.email=x@x commit-tree $(git hash-object -t tree /dev/null) < /dev/null) || : | |
- name: Clone the repository | |
uses: actions/checkout@v4 | |
- name: Cargo Cache | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
target/ | |
key: ${{ matrix.profile }}-cargo-test | |
- name: Setup Node and cache | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 16 | |
cache: 'yarn' | |
cache-dependency-path: | | |
etc/eth-contracts | |
etc/tests/uniswap | |
- name: Install dependencies | |
run: cargo +stable make -V || cargo +stable install cargo-make | |
- name: Build main contract | |
run: | | |
case ${{ matrix.profile }} in | |
mainnet-silo) | |
cargo make --profile mainnet build-test | |
;; | |
testnet-silo) | |
cargo make --profile testnet build-test | |
;; | |
*) | |
;; | |
esac | |
- name: Tests ${{ matrix.profile }} | |
run: cargo make --profile ${{ matrix.profile }} test-flow | |
test_modexp: | |
name: Test modexp suite ${{ matrix.profile }} | |
runs-on: github-hosted-heavy-runner | |
strategy: | |
fail-fast: false | |
matrix: | |
profile: [ mainnet, testnet ] | |
steps: | |
- name: Potential broken submodules fix | |
run: | | |
git checkout -f $(git -c user.name=x -c user.email=x@x commit-tree $(git hash-object -t tree /dev/null) < /dev/null) || : | |
- name: Clone the repository | |
uses: actions/checkout@v4 | |
- name: Cargo Cache | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
target/ | |
key: ${{ matrix.profile }}-cargo-modexp-test | |
- name: Install dependencies | |
run: cargo +stable make -V || cargo +stable install cargo-make | |
- name: Test ${{ matrix.profile }} bench-modexp | |
run: cargo make --profile ${{ matrix.profile }} bench-modexp | |
env: | |
CARGO_TERM_COLOR: always | |
CARGO_INCREMENTAL: 0 |