-
-
Notifications
You must be signed in to change notification settings - Fork 24
71 lines (54 loc) · 1.74 KB
/
ci.yaml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: CI
on:
push:
branches:
- main
workflow_dispatch:
workflow_call:
pull_request:
permissions:
checks: write
contents: read
jobs:
ci:
name: Continuous Integration
runs-on: ubuntu-latest
defaults:
run:
shell: bash
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
- name: Install dependencies
run: npm install
- name: Create sub-checks
run: npx zci init
- name: Formatting
run: npx zci run format "npm run format:check"
- name: Build
run: npx zci run build "npm run build"
- name: Linting
run: npx zci run lint "npm run lint"
- name: 'Unit tests: common'
run: npx zenfs-test -pfwC --common
- name: 'Unit tests: InMemory'
run: npx zenfs-test -pfwC tests/setup/memory.ts
- name: 'Unit tests: contexts'
run: npx zenfs-test -pfwC tests/setup/context.ts
- name: 'Unit tests: Index'
run: npx zenfs-test -pfwC tests/setup/index.ts
- name: 'Unit tests: Port'
run: npx zenfs-test -pfwC tests/setup/port.ts
- name: 'Unit tests: Overlay+Fetch'
run: tests/fetch/run.sh -wC
- name: Report coverage
run: npx zenfs-test --report
- name: Cleanup sub-checks
if: always()
run: npx zci cleanup