Skip to content

Merge pull request #87 from keyper-labs/feature/reduce-bytesize-code #595

Merge pull request #87 from keyper-labs/feature/reduce-bytesize-code

Merge pull request #87 from keyper-labs/feature/reduce-bytesize-code #595

Workflow file for this run

on: [push]
name: test
jobs:
check:
strategy:
fail-fast: true
name: Foundry project
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: foundry-toolchain
uses: foundry-rs/[email protected]
- name: Set Env Vars
env:
MASTER_COPY_ADDRESS: "0xd4a1E956fFe2D07CD71c8fABf538f2BfC0e3899B"
PROXY_FACTORY_ADDRESS: "0xEAb613456d3efD309101BB02872BEdCecE2879E2"
PALMERA_MODULE_ADDRESS: "0xc74f6cAFb3e89006FE9c0E8Be8Dc06888e178F1b"
OWNER_1: "0x9CDd325E49A6a8a82288fdC3B6C14b25221D1Cfa"
OWNER_2: "0xEd4AD3605740D6a9232e05F4d8A2b3377f81a8AA"
THRESHOLD: 1
FOUNDRY_VIA_IR: true
ACCOUNTS: 300
INFURA_KEY: ${{ secrets.INFURA_KEY }}
ALCHEMY_KEY: ${{ secrets.ALCHEMY_KEY }}
run: |
touch .env
echo "MASTER_COPY_ADDRESS=$MASTER_COPY_ADDRESS" >> .env
echo "PROXY_FACTORY_ADDRESS=$PROXY_FACTORY_ADDRESS" >> .env
echo "PALMERA_MODULE_ADDRESS=$PALMERA_MODULE_ADDRESS" >> .env
echo "OWNER_1=$OWNER_1" >> .env
echo "OWNER_2=$OWNER_2" >> .env
echo "THRESHOLD=$THRESHOLD" >> .env
echo "FOUNDRY_VIA_IR=$FOUNDRY_VIA_IR" >> .env
echo "ACCOUNTS=$ACCOUNTS" >> .env
echo "INFURA_KEY=$INFURA_KEY" >> .env
echo "ALCHEMY_KEY=$ALCHEMY_KEY" >> .env
- name: Run Tests
run: forge test --no-match-contract 'Skip*'
- name: Run Coverage
run: forge test --gas-report --fuzz-runs 1000 -vvv --no-match-contract='Skip*'
- name: Install nvm and use Node version from .nvmrc
run: |
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
. ~/.nvm/nvm.sh
nvm install
nvm use
- name: Setup Yarn cache
uses: actions/cache@v2
with:
path: ~/.cache/yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y python3 python3-distutils g++ make
- name: Install node-gyp
run: |
npm install -g node-gyp
- name: Install dependencies using Yarn
run: |
yarn install
- name: Run Hardhat tests with Yarn
run: |
yarn test
id: hardhat-test