Skip to content

Added action.

Added action. #8

Workflow file for this run

name: Run Unit Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
unit-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
name: Checkout repository 🫠
- name: Setup Node
uses: actions/setup-node@v3
- uses: actions/cache@v3
id: npm-cache
with:
path: ~/.npm
key: npm-${{ hashFiles('**/package-lock.json') }}
- run: npm ci
- run: npm test
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
- uses: actions/cache@v3
id: npm-cache
with:
path: ~/.npm
key: npm-${{ hashFiles('**/package-lock.json') }}
- run: npm ci
- run: npm run build