fix(test): update test reference #20
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Unit Tests | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- src/** | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
tests: | |
runs-on: ubuntu-latest | |
name: Tests | |
if: | | |
( | |
!contains(github.event.head_commit.message, '[skip ci]') && | |
!contains(github.event.head_commit.message, 'version bump') | |
) | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Install Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20 | |
registry-url: 'https://registry.npmjs.org' | |
- name: Install dependencies | |
run: npm install | |
- name: Run tests | |
run: npm test | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v2 | |
if: failure() | |
with: | |
name: unit-tests | |
path: ${{ github.workspace }}/coverage/ | |
retention-days: 5 |