Skip to content

v0.2.5 Maintenance Release #7

v0.2.5 Maintenance Release

v0.2.5 Maintenance Release #7

Workflow file for this run

name: Release Unit Testing
on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Triggers the workflow on pull request events
pull_request:
branches:
- main
- 'release/**'
env:
DEFAULT_NODE_VERSION: 14
jobs:
tests:
name: Unit tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [8.x, 10.x, 12.x, 14.x, 16.x, 17.x]
steps:
- name: Checkout Code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
# https://github.com/marketplace/actions/setup-node-js-environment
with:
node-version: ${{ matrix.node-version }}
- name: Cache node_modules
uses: actions/cache@v2
id: cache-nodemodules
with:
path: node_modules
key: ${{ runner.os }}-${{ matrix.node-version }}-nodemodules-${{ hashFiles('**/package-lock.json') }}
- name: Install dependencies
if: ${{ steps.cache-nodemodules.outputs.cache-hit != 'true' }}
run: npm ci
- name: Unit tests
run: npm test