Skip to content

Commit d4c30ac

Browse files
committed
ci(core): seperate amazonq and toolkit ci runners
1 parent b7ce8b4 commit d4c30ac

File tree

1 file changed

+12
-20
lines changed

1 file changed

+12
-20
lines changed

.github/workflows/node.js.yml

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ jobs:
126126
matrix:
127127
node-version: [18.x]
128128
vscode-version: [minimum, stable, insiders]
129+
package: [amazonq, toolkit]
129130
env:
130131
VSCODE_TEST_VERSION: ${{ matrix.vscode-version }}
131132
NODE_OPTIONS: '--max-old-space-size=8192'
@@ -141,28 +142,17 @@ jobs:
141142
- name: Tests
142143
uses: coactions/setup-xvfb@v1
143144
with:
144-
run: npm test
145-
- name: Code coverage (Toolkit)
145+
run: npm run test -w packages/${{ matrix.package }}
146+
- name: Code coverage for ${{ matrix.package }}
146147
env:
147148
# Unset NODE_OPTIONS because of https://github.com/codecov/uploader/issues/475
148149
NODE_OPTIONS: ''
149150
if: ${{ github.repository == 'aws/aws-toolkit-vscode' && github.event_name == 'pull_request' && github.base_ref == 'master' }}
150151
uses: codecov/codecov-action@v5
151152
with:
152-
flags: macos-toolkit-unittests
153+
flags: macos-${{ matrix.package }}-unittests
153154
verbose: true
154-
file: ./coverage/toolkit/lcov.info
155-
token: ${{ secrets.CODECOV_TOKEN }}
156-
- name: Code coverage (Amazon Q)
157-
env:
158-
# Unset NODE_OPTIONS because of https://github.com/codecov/uploader/issues/475
159-
NODE_OPTIONS: ''
160-
if: ${{ github.repository == 'aws/aws-toolkit-vscode' && github.event_name == 'pull_request' && github.base_ref == 'master' }}
161-
uses: codecov/codecov-action@v5
162-
with:
163-
flags: macos-amazonq-unittests
164-
verbose: true
165-
file: ./coverage/amazonq/lcov.info
155+
file: ./coverage/${{ matrix.package }}/lcov.info
166156
token: ${{ secrets.CODECOV_TOKEN }}
167157

168158
web:
@@ -174,6 +164,7 @@ jobs:
174164
matrix:
175165
node-version: [18.x]
176166
vscode-version: [stable, insiders]
167+
package: [amazonq, toolkit]
177168
env:
178169
VSCODE_TEST_VERSION: ${{ matrix.vscode-version }}
179170
NODE_OPTIONS: '--max-old-space-size=8192'
@@ -189,7 +180,7 @@ jobs:
189180
- name: Tests
190181
uses: coactions/setup-xvfb@v1
191182
with:
192-
run: npm run testWeb
183+
run: npm run testWeb -w packages/${{ matrix.package }}
193184

194185
windows:
195186
needs: lint-commits
@@ -200,6 +191,7 @@ jobs:
200191
matrix:
201192
node-version: [18.x]
202193
vscode-version: [stable, insiders]
194+
package: [amazonq, toolkit]
203195
env:
204196
VSCODE_TEST_VERSION: ${{ matrix.vscode-version }}
205197
NODE_OPTIONS: '--max-old-space-size=8192'
@@ -211,15 +203,15 @@ jobs:
211203
node-version: ${{ matrix.node-version }}
212204
- run: npm ci
213205
- name: Tests
214-
run: npm test
215-
- name: Code coverage
206+
run: npm run test -w packages/${{ matrix.package }}
207+
- name: Code coverage for ${{ matrix.package }}
216208
env:
217209
# Unset NODE_OPTIONS because of https://github.com/codecov/uploader/issues/475
218210
NODE_OPTIONS: ''
219211
if: ${{ github.repository == 'aws/aws-toolkit-vscode' && github.event_name == 'pull_request' && github.base_ref == 'master' }}
220212
uses: codecov/codecov-action@v5
221213
with:
222-
flags: windows-unittests
214+
flags: windows-${{ matrix.package }}-unittests
223215
verbose: true
224-
file: ./coverage/lcov.info
216+
file: ./coverage/${{ matrix.package }}/lcov.info
225217
token: ${{ secrets.CODECOV_TOKEN }}

0 commit comments

Comments
 (0)