mirror of
https://github.com/datahaven-xyz/datahaven
synced 2026-05-24 01:38:32 +00:00
In this PR, we pin the forge version use in the linter task. When forge make a new release it brokes the linter task. In the future we can update the forge version explicitly. --------- Co-authored-by: Ahmad Kaouk <56095276+ahmadkaouk@users.noreply.github.com>
58 lines
1.4 KiB
YAML
58 lines
1.4 KiB
YAML
# Foundry Tests: CI for Foundry components (smart contracts for EigenLayer and Snowbridge interaction)
|
|
#
|
|
# Overview:
|
|
# 1. All Foundry Tests: Executes the full suite of Foundry tests found within the `./contracts` directory
|
|
|
|
name: Foundry AVS Smart Contract Tests
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
workflow_call:
|
|
|
|
env:
|
|
FOUNDRY_PROFILE: ci
|
|
|
|
jobs:
|
|
test:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
partition: [1]
|
|
|
|
name: Foundry Tests
|
|
runs-on: ubuntu-latest
|
|
defaults:
|
|
run:
|
|
working-directory: contracts
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
|
|
- name: Install Foundry
|
|
uses: foundry-rs/foundry-toolchain@v1
|
|
with:
|
|
version: v1.4.3
|
|
|
|
- name: Cache Foundry libraries
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: contracts/lib
|
|
key: ${{ runner.os }}-foundry-libs-${{ hashFiles('contracts/.gitmodules') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-foundry-libs-
|
|
|
|
- name: Cache Foundry build artifacts
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
contracts/out
|
|
contracts/cache
|
|
key: ${{ runner.os }}-foundry-build-${{ hashFiles('contracts/foundry.toml', 'contracts/**/*.sol') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-foundry-build-
|
|
|
|
- run: forge --version
|
|
- run: forge fmt --check
|
|
- run: forge build --sizes
|
|
- run: forge test -vvv
|