Skip to content

Commit de95cd7

Browse files
committed
ci(test-optimization): run datadog-plugin-jest unit spec
`packages/datadog-plugin-jest/test/util.spec.js` is matched by `test:plugins`' glob but no workflow set `PLUGINS=jest` for `test:plugins:ci`; the existing `integration-jest` matrix runs `integration-tests/jest/*.spec.js` only, which does not cover the plugin package's own unit tests. The new joint check flagged it as never reached. Add a single `jest:` job invoking the `plugins/test` composite action. `util.spec.js` is a pure unit test on `getFormattedJestTestParameters` and `getJestSuitesToRun`, so no service containers or matrix axes are needed beyond what `plugins/test` already covers (oldest-maintenance and latest Node).
1 parent 963c02c commit de95cd7

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

.github/workflows/test-optimization.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,19 @@ jobs:
206206
flags: test-optimization-jest-${{ matrix.version }}-${{ matrix.jest-version }}
207207
dd_api_key: ${{ steps.dd-sts.outputs.api_key }}
208208

209+
# Unit tests for `packages/datadog-plugin-jest`. The `integration-jest` matrix above only runs
210+
# `integration-tests/jest/*.spec.js`, so this is the only CI invocation whose glob expands to
211+
# cover `packages/datadog-plugin-jest/test/util.spec.js`.
212+
jest:
213+
runs-on: ubuntu-latest
214+
permissions:
215+
id-token: write
216+
env:
217+
PLUGINS: jest
218+
steps:
219+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
220+
- uses: ./.github/actions/plugins/test
221+
209222
integration-cucumber:
210223
strategy:
211224
fail-fast: false

0 commit comments

Comments
 (0)