Repository navigation
51 lines (43 loc) · 1.48 KB
/
Copy pathtest.yml
File metadata and controls
51 lines (43 loc) · 1.48 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
name: Tests
on:
pull_request:
branches: [dev, beta, main, "1.x"]
workflow_dispatch:
jobs:
test:
name: ${{ matrix.os }} / Node ${{ matrix.node }}
runs-on: ${{ matrix.os }}
strategy:
# One platform failing should not hide the result on the others.
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
node: ['24', '26']
steps:
- name: checkout cli
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
with:
persist-credentials: false
# Installed as a standalone executable: a pinned pnpm that needs no Node of its own,
# so the matrix Node only ever runs the CLI's build and tests.
- name: setup pnpm
uses: pnpm/action-setup@a15d269cd4658e1107c09f1fabf4cbd7bd1f308a # v4.4.0
with:
version: 11.0.8
standalone: true
- name: setup node
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: ${{ matrix.node }}
cache: 'pnpm'
cache-dependency-path: pnpm-lock.yaml
- name: install dependencies
run: pnpm install --frozen-lockfile
- name: build
run: pnpm build
# The portal build runs Vite in a temp project whose node_modules is one link per
# dependency, so it is the step most likely to break per platform.
- name: test
run: pnpm test
env:
APIMATIC_E2E: '1'