Skip to content

v1.10.4 Update tests and hr #69

v1.10.4 Update tests and hr

v1.10.4 Update tests and hr #69

Workflow file for this run

# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: CI/CD
on:
push:
branches: ['master']
pull_request:
branches: ['master']
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- name: Restore node_modules from cache
uses: actions/cache@v2
with:
path: |
node_modules
*/*/node_modules
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install dependencies
run: npm install --force
- name: Lint
run: npm run lint
- name: Spell check
run: npm run spellcheck
- name: Tests
run: npm test -- --coverage
- name: Upload coverage to Codecov
if: github.event_name == 'pull_request'
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
- name: Build
run: npm run build
# - uses: actions/upload-artifact@v3
# with:
# name: out
# path: build/
- name: Deploy
if: github.event_name == 'push'
uses: JamesIves/github-pages-deploy-action@releases/v3
with:
GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
BRANCH: gh-pages
FOLDER: build