Skip to content

Commit

Permalink
Add test github action
Browse files Browse the repository at this point in the history
  • Loading branch information
Zvonimir authored and Zvonimir committed Feb 26, 2025
1 parent 1044949 commit 320624e
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Hardhat tests
on: [push, pull_request]

jobs:
test:
runs-on: ubuntu-latest
name: Hardhat tests
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
cache: 'npm'

- name: Cache node modules
id: cache-node-modules
uses: actions/cache@v3
with:
path: 'node_modules'
key: node-modules-${{ hashFiles('package-lock.json') }}

- name: Install dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm ci

- name: Run tests
run: npx hardhat test

0 comments on commit 320624e

Please sign in to comment.