-
Notifications
You must be signed in to change notification settings - Fork 2
57 lines (44 loc) · 1.01 KB
/
tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: "Tests"
on:
push:
paths:
- "lib/**"
- "server/**"
- "test/**"
- ".github/workflows/tests.yml"
- "package.json"
- "package-lock.json"
pull_request:
paths:
- "lib/**"
- "server/**"
- "test/**"
- ".github/workflows/tests.yml"
- "package.json"
- "package-lock.json"
jobs:
build:
name: "Run tests"
runs-on: ubuntu-latest
steps:
- name: "Checkout the repository"
uses: actions/checkout@v4
- name: "Set up Node 18"
uses: actions/setup-node@v4
with:
node-version: 18
- name: "Install Node dependencies"
run: |
npm install
- name: "Start the test server"
run: |
npx pm2 start -f test/env/test-server.js --name=obsidian-proxy-server &
- name: "Run lint"
run: |
npm run lint
- name: "Run tests"
run: |
npm run test
- name: "Stop the test server"
run: |
npx pm2 kill