Skip to content

Commit

Permalink
adds github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
peetzweg committed Feb 6, 2024
1 parent 07dd85b commit 5bc8bb1
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Run Testsuite

on:
pull_request:
branches:
- master

jobs:
release:
name: Release
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20]
pnpm-version: [8.11]
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
fetch-depth: 0
submodules: true

- name: Set up pnpm action ${{ matrix.pnpm-version }}
uses: pnpm/action-setup@v2
with:
version: ${{ matrix.pnpm-version }}

- name: Set up Node ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
cache: 'pnpm'
node-version: ${{ matrix.node-version }}

- name: Install Dependencies
run: pnpm install --frozen-lockfile

- name: Run Unit Tests
run: pnpm test:ci

- name: Run Coverage Analysis
run: pnpm coverage
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"scripts": {
"build": "tsup",
"test": "vitest",
"test:ci": "vitest run",
"coverage": "vitest run --coverage",
"dev": "tsup --watch",
"dev:react-example": "concurrently \"pnpm run dev\" \"pnpm run -F \"{examples/react-ts}\" dev\"",
Expand Down

0 comments on commit 5bc8bb1

Please sign in to comment.