feature: add jest tests workflow and coverage report #1
Workflow file for this run
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
on: [ "push", "pull_request" ] | |
name: Unit Tests | |
jobs: | |
test: | |
name: Run Unit Tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Use Node.js 20.x | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20.x | |
- name: Install deps and run tests | |
run: | | |
npm install -g pnpm@latest | |
pnpm i | |
pnpm test:ci:coverage | |
- name: Report to Coveralls | |
uses: coverallsapp/github-action@v2 | |
with: | |
github-token: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
file: coverage/lcov.info | |
allow-empty: true |