Improve initialization script with liquidity and whitelists #60
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: Smart Contract Tests | |
on: | |
push: | |
branches: | |
- '*' | |
pull_request: | |
branches: | |
- develop | |
- main | |
env: | |
FOUNDRY_PROFILE: ci | |
ARBITRUM_SEPOLIA_RPC_URL: ${{ secrets.ARBITRUM_SEPOLIA_RPC_URL }} | |
ETH_SEPOLIA_RPC_URL: ${{ secrets.ETH_SEPOLIA_RPC_URL }} | |
SCROLL_SEPOLIA_RPC_URL: ${{ secrets.SCROLL_SEPOLIA_RPC_URL }} | |
PRIVATE_KEY: ${{ secrets.PRIVATE_KEY }} | |
BACKEND_EOA: ${{ secrets.BACKEND_EOA }} | |
BACKEND_PK: ${{ secrets.BACKEND_PK }} | |
NFT_BASE_URI: https://dev.back.chatterpay.net/nft/metadata/opensea/ | |
FOUNDRY_DISABLE_NIGHTLY_WARNING: 1 | |
jobs: | |
check: | |
strategy: | |
fail-fast: true | |
name: Smart Contract Tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Set up cache for Foundry | |
uses: actions/cache@v3 | |
with: | |
path: | | |
.forge-cache | |
lib | |
key: ${{ runner.os }}-forge-cache-${{ hashFiles('**/*.sol') }} | |
- name: Initialize and update submodules | |
run: git submodule update --init --recursive | |
- name: Install Foundry | |
uses: foundry-rs/foundry-toolchain@v1 | |
with: | |
version: nightly | |
- name: Run Forge build | |
run: | | |
forge --version | |
forge build --sizes 2>&1 | tee forge_build.log || (grep -q "error:" forge_build.log && exit 1 || exit 0) | |
id: build | |
- name: Run Forge tests | |
run: | | |
FOUNDRY_PROFILE=local forge test \ | |
--fork-url "$ARBITRUM_SEPOLIA_RPC_URL" \ | |
-vvv \ | |
--match-path "test/modules/*" \ | |
--ffi \ | |
-j 8 \ | |
--gas-report \ | |
--cache-path .forge-cache 2>&1 | tee forge_test.log || (grep -q "error:" forge_test.log && exit 1 || exit 0) | |
id: test |