Skip to content

#441: ALMF - depositParam1 and withdrawParam1 are allowed to set depo… #1736

#441: ALMF - depositParam1 and withdrawParam1 are allowed to set depo…

#441: ALMF - depositParam1 and withdrawParam1 are allowed to set depo… #1736

Workflow file for this run

name: Forge
on:
push:
branches:
- main
pull_request: { }
workflow_dispatch: { }
env:
FOUNDRY_PROFILE: ci
jobs:
check:
strategy:
fail-fast: true
name: Test, coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
fetch-tags: true
- name: Ensure submodules are on correct commits
run: |
git submodule sync --recursive
git submodule update --init --recursive
git submodule status
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: stable
# Restore Foundry RPC cache to avoid hitting paid RPC endpoints on every CI run.
# This cache stores responses from all networks (Ethereum, Arbitrum, Base, etc.)
# and allows forge to reuse previously fetched block/state data.
# Without this step, every CI run would re-query RPC providers from scratch,
# quickly exhausting rate limits on paid RPC keys.
- name: Restore RPC cache
uses: actions/cache@v3
with:
path: ~/.foundry/cache/rpc
key: rpc-cache
restore-keys: rpc-cache
- name: Run forge build
run: |
forge --version
forge build --sizes
id: build
- name: Run forge test
run: |
forge test --nmc SkipOnCiTest -vvv
env:
POLYGON_RPC_URL: ${{secrets.POLYGON_RPC_URL}}
BASE_RPC_URL: ${{secrets.BASE_RPC_URL}}
ARBITRUM_RPC_URL: ${{secrets.ARBITRUM_RPC_URL}}
ETHEREUM_RPC_URL: ${{secrets.ETHEREUM_RPC_URL}}
REAL_RPC_URL: ${{secrets.REAL_RPC_URL}}
SONIC_RPC_URL: ${{secrets.SONIC_RPC_URL}}
AVALANCHE_RPC_URL: ${{secrets.AVALANCHE_RPC_URL}}
PLASMA_RPC_URL: ${{secrets.PLASMA_RPC_URL}}
id: test
- name: Run Forge coverage
run: |
forge coverage --nmc SkipOnCiTest --report lcov
env:
POLYGON_RPC_URL: ${{secrets.POLYGON_RPC_URL}}
BASE_RPC_URL: ${{secrets.BASE_RPC_URL}}
ARBITRUM_RPC_URL: ${{secrets.ARBITRUM_RPC_URL}}
ETHEREUM_RPC_URL: ${{secrets.ETHEREUM_RPC_URL}}
REAL_RPC_URL: ${{secrets.REAL_RPC_URL}}
SONIC_RPC_URL: ${{secrets.SONIC_RPC_URL}}
AVALANCHE_RPC_URL: ${{secrets.AVALANCHE_RPC_URL}}
PLASMA_RPC_URL: ${{secrets.PLASMA_RPC_URL}}
id: coverage
- name: Upload coverage lcov report to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
- name: Upload RPC cache
uses: actions/upload-artifact@v4
with:
name: rpc-cache
path: ~/.foundry/cache/rpc
- name: Upload lcov.info as artifact
uses: actions/upload-artifact@v4
with:
name: lcov-report
path: lcov.info