mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-12-10 13:59:40 +00:00
Add unit test workflow
This commit is contained in:
parent
5fcd23409a
commit
a1af672c7c
1 changed files with 30 additions and 0 deletions
30
.github/workflows/unit-tests.yml
vendored
Normal file
30
.github/workflows/unit-tests.yml
vendored
Normal file
|
|
@ -0,0 +1,30 @@
|
||||||
|
name: Unit Tests
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
branch:
|
||||||
|
description: 'Branch name'
|
||||||
|
required: true
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ref: ${{ github.event_name != 'workflow_dispatch' && github.ref_name || inputs.branch}}
|
||||||
|
|
||||||
|
- name: Set up Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: npm ci
|
||||||
|
|
||||||
|
- name: Run tests
|
||||||
|
run: npm test
|
||||||
Loading…
Add table
Add a link
Reference in a new issue