Skip to content

Conversation

@joyeecheung
Copy link
Member

Previously whenever one of the test case fails in the CI, it barely logged anything useful in the CI and it was difficult to nail down the specific failing case with a local reproduction, especially when the test fixutre is inline JavaScript. This patch:

  • Puts all the inline JavaScript in on-disk fixtures so that they can be re-run easily.
  • Split the tests into individual files so that it's easier to nail down the failure
  • Use spawnSyncAndAssert which logs useful information when the child process does not behave as expected.
  • Rename the tests as module-hooks/test-async-loader-hooks-* because they belong to the module hooks test suite and are not esm-specific.

Refs: https://github.com/nodejs/reliability/blob/main/reports/2026-01-13.md

cc @RafaelGSS @marco-ippolito

@nodejs-github-bot nodejs-github-bot added esm Issues and PRs related to the ECMAScript Modules implementation. loaders Issues and PRs related to ES module loaders module Issues and PRs related to the module subsystem. needs-ci PRs that need a full CI run. test Issues and PRs related to the tests. labels Jan 13, 2026
@codecov
Copy link

codecov bot commented Jan 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.53%. Comparing base (1bd7f62) to head (110ecb7).
⚠️ Report is 24 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #61374      +/-   ##
==========================================
+ Coverage   88.51%   88.53%   +0.01%     
==========================================
  Files         704      704              
  Lines      208739   208793      +54     
  Branches    40274    40314      +40     
==========================================
+ Hits       184770   184858      +88     
+ Misses      15968    15914      -54     
- Partials     8001     8021      +20     

see 47 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Previously whenever one of the test case fails in the CI, it
barely logged anything useful in the CI and it was difficult to
nail down the specific failing case with a local reproduction,
especially when the test fixutre is inline JavaScript. This patch:

- Puts all the inline JavaScript in on-disk fixtures so that
  they can be re-run easily.
- Split the tests into individual files so that it's easier to nail
  down the failure
- Use spawnSyncAndAssert which logs useful information when the child
  process does not behave as expected.
- Rename the tests as module-hooks/test-async-loader-hooks-* because
  they belong to the module hooks test suite and are not esm-specific.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

esm Issues and PRs related to the ECMAScript Modules implementation. loaders Issues and PRs related to ES module loaders module Issues and PRs related to the module subsystem. needs-ci PRs that need a full CI run. test Issues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants