Skip to content

Commit

Permalink
Tweak ci
Browse files Browse the repository at this point in the history
  • Loading branch information
eternauta1337 committed Feb 24, 2024
1 parent c000bc4 commit 37dfc1a
Showing 1 changed file with 21 additions and 14 deletions.
35 changes: 21 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,25 +10,28 @@ jobs:
setup:
runs-on: ubuntu-latest
outputs:
cache-key: ${{ steps.cache-keys.outputs.key }}
env:
ETHERSCAN_API_KEY: ${{ secrets.ETHERSCAN_API_KEY }}
ALCHEMY_API_KEY: ${{ secrets.ALCHEMY_API_KEY }}
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}

cache-key: ${{ steps.cache.outputs.key }}
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: 20.x
- run: npm ci
cache: 'npm'
- name: Install Dependencies
run: npm ci
- run: npm run build --if-present
- run: npm run compile --if-present
- name: Start local chain
run: |
npm run chain &
sleep 10
run: npm run chain & sleep 10
- name: Cache node modules
id: cache
uses: actions/cache@v2
with:
path: '**/node_modules'
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
test:
needs: setup
Expand All @@ -45,14 +48,18 @@ jobs:
ethernaut-toolbox,
ethernaut-ui,
]
fail-fast: false # Keep running other jobs even if one fails
fail-fast: false
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: 20.x
cache: 'npm'
cache-dependency-path: '**/package-lock.json'
- name: Restore Dependencies from Cache
uses: actions/cache@v2
with:
path: '**/node_modules'
key: ${{ needs.setup.outputs.cache-key }}
- name: Test ${{ matrix.package }}
run: cd packages/${{ matrix.package }} && npm t

0 comments on commit 37dfc1a

Please sign in to comment.