-
Notifications
You must be signed in to change notification settings - Fork 76
57 lines (54 loc) · 1.65 KB
/
node-package.yml
File metadata and controls
57 lines (54 loc) · 1.65 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
name: Node.js Package
on:
push:
branches:
- main
paths:
- 'nodejs/**'
- '.github/workflows/node-package.yml'
pull_request:
paths:
- 'nodejs/**'
- '.github/workflows/node-package.yml'
schedule:
- cron: '0 0 */7 * *'
workflow_dispatch:
defaults:
run:
working-directory: ./nodejs
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node-version: ['18.x', '20.x', '22.x']
steps:
- uses: actions/checkout@v4
- name: Set up NodeJS ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: npm ci
- name: Lint
run: npm run lint
- name: Type check
run: npm run test:types
- name: Offline tests (PR gate)
run: npm run test:offline
- name: Integration tests (live FR24)
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' || github.event_name == 'push'
uses: nick-fields/retry@v3
with:
timeout_minutes: 10
max_attempts: 3
command: cd nodejs && npm run test:integration
continue-on-error: ${{ github.event_name == 'push' }}
- name: Dependency audit (informational)
# Informational only: surfaces high-severity advisories as a soft-fail
# without blocking PRs. Re-enable enforcement (drop continue-on-error)
# once the audit baseline is clean.
if: matrix.node-version == '22.x'
continue-on-error: true
run: cd nodejs && npm audit --omit=dev --audit-level=high