Skip to content

Commit 85f9e9a

Browse files
committed
ci: update Node.js version to 22.x and restructure test jobs in build.yml
1 parent e6b2410 commit 85f9e9a

File tree

1 file changed

+35
-31
lines changed

1 file changed

+35
-31
lines changed

.github/workflows/build.yml

Lines changed: 35 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -12,48 +12,56 @@ on:
1212
jobs:
1313
lint:
1414
runs-on: ubuntu-latest
15-
strategy:
16-
matrix:
17-
node-version: [20.x]
1815

1916
steps:
2017
- uses: actions/checkout@v4
21-
- name: Use Node.js ${{ matrix.node-version }}
18+
- name: Use Node.js
2219
uses: actions/setup-node@v4
2320
with:
24-
node-version: ${{ matrix.node-version }}
21+
node-version: 22.x
2522
- name: Install dependencies
2623
run: yarn install --immutable
2724
- name: Run lint
2825
run: yarn lint
2926

30-
test:
31-
runs-on: ${{ matrix.os }}
27+
test-cli-core:
28+
runs-on: ubuntu-latest
29+
steps:
30+
- uses: actions/checkout@v4
31+
- name: Use Node.js
32+
uses: actions/setup-node@v4
33+
with:
34+
node-version: 22.x
35+
- name: Install dependencies
36+
run: yarn install --immutable
37+
- name: Run tests for cli-core
38+
run: yarn test run --project=@tsed/cli-core
3239

33-
strategy:
34-
matrix:
35-
os: [ubuntu-latest, windows-latest]
36-
node-version: [20.x]
37-
exclude:
38-
# - os: macos-latest
39-
# node-version: 12.x
40-
# - os: macos-latest
41-
# node-version: 15.x
42-
# - os: windows-latest
43-
# node-version: 12.x
44-
- os: windows-latest
45-
node-version: 20.x
40+
test-cli:
41+
runs-on: ubuntu-latest
42+
steps:
43+
- uses: actions/checkout@v4
44+
- name: Use Node.js
45+
uses: actions/setup-node@v4
46+
with:
47+
node-version: 22.x
48+
- name: Install dependencies
49+
run: yarn install --immutable
50+
- name: Run tests for cli
51+
run: yarn test run --project=@tsed/cli
4652

53+
test-plugins:
54+
runs-on: "ubuntu-latest"
4755
steps:
4856
- uses: actions/checkout@v4
49-
- name: Use Node.js ${{ matrix.node-version }}
57+
- name: Use Node.js
5058
uses: actions/setup-node@v4
5159
with:
52-
node-version: ${{ matrix.node-version }}
60+
node-version: 22.x
5361
- name: Install dependencies
5462
run: yarn install --immutable
55-
- name: Run test
56-
run: yarn test
63+
- name: Run tests for other packages
64+
run: yarn test --project="@tsed/cli-plugin-*"
5765

5866
build:
5967
runs-on: ubuntu-latest
@@ -77,19 +85,15 @@ jobs:
7785

7886
deploy-packages:
7987
runs-on: ubuntu-latest
80-
needs: [lint, test, build]
88+
needs: [lint, test-cli-core, test-cli, test-plugins, build]
8189
if: ${{ github.event_name != 'pull_request' && (contains(github.ref, 'master') || contains(github.ref, 'alpha') || contains(github.ref, 'beta') || contains(github.ref, 'rc')) }}
8290

83-
strategy:
84-
matrix:
85-
node-version: [20.x]
86-
8791
steps:
8892
- uses: actions/checkout@v4
89-
- name: Use Node.js ${{ matrix.node-version }}
93+
- name: Use Node.js
9094
uses: actions/setup-node@v4
9195
with:
92-
node-version: ${{ matrix.node-version }}
96+
node-version: 22.x
9397
- name: Install dependencies
9498
run: yarn install --frozen-lockfile --network-timeout 500000
9599
- name: Release packages

0 commit comments

Comments
 (0)