-
Notifications
You must be signed in to change notification settings - Fork 0
149 lines (136 loc) · 4.01 KB
/
Copy pathci.yml
File metadata and controls
149 lines (136 loc) · 4.01 KB
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
name: CI
on:
workflow_dispatch:
push:
branches: [ master, main ]
pull_request:
permissions:
contents: read
jobs:
build-and-test:
runs-on: ubuntu-latest
timeout-minutes: 15
defaults:
run:
working-directory: universal-refiner
steps:
- uses: actions/checkout@v5
- name: Setup Node 22
uses: actions/setup-node@v5
with:
node-version: '22'
- name: Install dependencies
run: npm ci --no-fund
- name: Rebuild native modules
run: npm rebuild better-sqlite3
- name: Build
run: npm run build
- name: Run tests
run: npm run test:coverage
acceptance:
runs-on: ubuntu-latest
timeout-minutes: 15
defaults:
run:
working-directory: universal-refiner
strategy:
fail-fast: false
matrix:
model-order:
- primary
- reversed
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '22'
cache: npm
cache-dependency-path: universal-refiner/package-lock.json
- run: npm ci --no-fund
- run: npm rebuild better-sqlite3
- run: npm run build
- name: Run all-tool and provider acceptance
run: npm run test:acceptance
- name: Run fake-model semantic acceptance
env:
PROMPT_REFINER_PRIMARY_MODEL: ${{ matrix.model-order == 'primary' && 'gemma3:12b' || 'gemma3:1b' }}
PROMPT_REFINER_FALLBACK_MODEL: ${{ matrix.model-order == 'primary' && 'gemma3:1b' || 'gemma3:12b' }}
run: npm run acceptance:semantic
stress:
runs-on: ubuntu-latest
timeout-minutes: 15
defaults:
run:
working-directory: universal-refiner
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '22'
cache: npm
cache-dependency-path: universal-refiner/package-lock.json
- run: npm ci --no-fund
- run: npm rebuild better-sqlite3
- run: npm run build
- name: Run restart and in-process concurrency tests
run: npm run test:stress
- name: Run multi-process EventStore stress
env:
PROMPT_REFINER_STRESS_WORKERS: '4'
PROMPT_REFINER_STRESS_WRITES: '100'
run: npm run stress:event-store
windows:
runs-on: windows-latest
timeout-minutes: 20
defaults:
run:
working-directory: universal-refiner
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '22'
cache: npm
cache-dependency-path: universal-refiner/package-lock.json
- run: npm ci --no-fund
- run: npm rebuild better-sqlite3
- run: npm run build
- run: npm run test:coverage
- run: npm run test:acceptance
- run: npm run test:stress
supply-chain:
runs-on: ubuntu-latest
timeout-minutes: 15
defaults:
run:
working-directory: universal-refiner
steps:
- uses: actions/checkout@v5
- uses: actions/setup-node@v5
with:
node-version: '22'
cache: npm
cache-dependency-path: universal-refiner/package-lock.json
- run: npm ci --no-fund
- run: npm run security:audit
- run: npm run security:secrets
- run: npm run build
- run: npm run package:check
release-gate:
if: always()
needs: [build-and-test, acceptance, stress, windows, supply-chain]
runs-on: ubuntu-latest
steps:
- name: Require every enterprise gate
env:
BUILD: ${{ needs['build-and-test'].result }}
ACCEPTANCE: ${{ needs.acceptance.result }}
STRESS: ${{ needs.stress.result }}
WINDOWS: ${{ needs.windows.result }}
SUPPLY_CHAIN: ${{ needs['supply-chain'].result }}
run: |
test "$BUILD" = "success"
test "$ACCEPTANCE" = "success"
test "$STRESS" = "success"
test "$WINDOWS" = "success"
test "$SUPPLY_CHAIN" = "success"