mirror of
https://github.com/vrtmrz/obsidian-livesync.git
synced 2026-03-30 13:45:19 +00:00
45 lines
1001 B
YAML
45 lines
1001 B
YAML
# Run Unit test without Harnesses
|
|
name: unit-ci
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- main
|
|
- beta
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 30
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '24.x'
|
|
cache: 'npm'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
# unit tests do not require Playwright, so we can skip installing its dependencies to save time
|
|
# - name: Install test dependencies (Playwright Chromium)
|
|
# run: npm run test:install-dependencies
|
|
|
|
- name: Run unit tests suite with coverage
|
|
run: npm run test:unit:coverage
|
|
|
|
- name: Upload coverage report
|
|
if: always()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: coverage-report
|
|
path: coverage/** |