Skip to content

test: shared bridge unit tests #183

test: shared bridge unit tests

test: shared bridge unit tests #183

Workflow file for this run

name: CI
on: pull_request
jobs:
lint:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ethereum
steps:
- name: Checkout the repository
uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: 18.18.0
cache: yarn
cache-dependency-path: ethereum/yarn.lock
- name: Install yarn
run: npm install -g yarn
- name: Install dependencies
run: yarn install
- name: Lint
run: yarn lint
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ethereum
steps:
- name: Checkout the repository
uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: 18.18.0
cache: yarn
cache-dependency-path: ethereum/yarn.lock
- name: Install yarn
run: npm install -g yarn
- name: Install dependencies
run: yarn install
- name: Build artifacts
run: yarn build
- name: Create cache
uses: actions/cache/save@v3
with:
key: artifacts-${{ github.sha }}
path: |
ethereum/artifacts
ethereum/cache
ethereum/typechain
test-hardhat:
needs: [build, lint]
runs-on: ubuntu-latest
defaults:
run:
working-directory: ethereum
steps:
- name: Checkout the repository
uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: 18.18.0
cache: yarn
cache-dependency-path: ethereum/yarn.lock
- name: Install yarn
run: npm install -g yarn
- name: Install dependencies
run: yarn install
- name: Restore artifacts cache
uses: actions/cache/restore@v3
with:
fail-on-cache-miss: true
key: artifacts-${{ github.sha }}
path: |
ethereum/artifacts
ethereum/cache
ethereum/typechain
- name: Run tests
run: yarn test --no-compile
test-foundry:
needs: [build, lint]
runs-on: ubuntu-latest
defaults:
run:
working-directory: ethereum
steps:
- name: Checkout the repository
uses: actions/checkout@v3
with:
submodules: "recursive"
- name: "Install Foundry"
uses: "foundry-rs/foundry-toolchain@v1"
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: 16.15.1
cache: yarn
cache-dependency-path: ethereum/yarn.lock
- name: Install yarn
run: npm install -g yarn
- name: Install dependencies
run: yarn install
- name: Restore artifacts cache
uses: actions/cache/restore@v3
with:
fail-on-cache-miss: true
key: artifacts-${{ github.sha }}
path: |
ethereum/artifacts
ethereum/cache
ethereum/typechain
- name: Run tests
run: forge test