-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Open
Labels
repo maintenancethings to do with maintenance of the repo, and not with code/docsthings to do with maintenance of the repo, and not with code/docstriageWaiting for team members to take a lookWaiting for team members to take a look
Description
Suggestion
I suggest we disable the fail-fast behavior for the CI unit tests. If a spurious test failure occurs, or multiple legitimate test failures occur, it's useful to see the rest of the test runs' results for a better feedback loop. (looks like this instead of this)
This would be as easy as adding fail-fast: false
to
typescript-eslint/.github/workflows/ci.yml
Lines 176 to 240 in 719213b
unit_tests: | |
name: Run Unit Tests | |
environment: ${{ (github.repository == 'typescript-eslint/typescript-eslint' && github.ref == 'refs/heads/main') && 'main' || '' }} # Have to specify per job | |
needs: [build] | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
exclude: | |
- os: windows-latest | |
node-version: 18 | |
os: [ubuntu-latest, windows-latest] | |
# just run on the oldest and latest supported versions and assume the intermediate versions are good | |
node-version: [18, 20] | |
package: | |
[ | |
'ast-spec', | |
'eslint-plugin', | |
'eslint-plugin-internal', | |
'parser', | |
'project-service', | |
'rule-tester', | |
'scope-manager', | |
'tsconfig-utils', | |
'type-utils', | |
'typescript-eslint', | |
'typescript-estree', | |
'utils', | |
'visitor-keys', | |
] | |
env: | |
NX_CI_EXECUTION_ENV: '${{ matrix.os }} - Node ${{ matrix.node-version }}' | |
COLLECT_COVERAGE: false | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 2 | |
- name: Install | |
uses: ./.github/actions/prepare-install | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Build | |
uses: ./.github/actions/prepare-build | |
# collect coverage on the primary node version | |
# we don't collect coverage on other node versions so they run faster | |
- name: Run unit tests with coverage for ${{ matrix.package }} | |
if: env.PRIMARY_NODE_VERSION == matrix.node-version && matrix.os == 'ubuntu-latest' | |
run: yarn nx run ${{ matrix.package }}:test -- --coverage | |
env: | |
CI: true | |
- name: Run unit tests for ${{ matrix.package }} | |
if: env.PRIMARY_NODE_VERSION != matrix.node-version || matrix.os != 'ubuntu-latest' | |
run: yarn nx test ${{ matrix.package }} | |
env: | |
CI: true | |
- name: Store coverage for uploading | |
if: env.PRIMARY_NODE_VERSION == matrix.node-version && matrix.os == 'ubuntu-latest' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ matrix.package }}-coverage | |
path: packages/${{ matrix.package }}/coverage/lcov.info | |
# Sadly 1 day is the minimum | |
retention-days: 1 |
Obviously potential downside is using more CI time
Additional Info
No response
Metadata
Metadata
Assignees
Labels
repo maintenancethings to do with maintenance of the repo, and not with code/docsthings to do with maintenance of the repo, and not with code/docstriageWaiting for team members to take a lookWaiting for team members to take a look