Repository navigation
fix(@angular/build): add splitting option to unit-test builder - #33961
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new splitting option (defaulting to true) to the unit-test builder schema for the Vitest runner. This option allows users to enable or disable code splitting for test execution, which can help resolve issues with live ESM bindings in Node.js environments. The Vitest build options have been updated to respect this configuration, and comprehensive unit tests have been added to verify the behavior of the splitting option. There are no review comments, and I have no additional feedback to provide.
Adds a `splitting` option to the unit-test builder to control code splitting for the test build with the Vitest runner. This option is enabled by default to optimize test bundling performance and memory consumption, avoiding issues during code coverage collection. For Node-based test environments where live ESM bindings across chunk boundaries cause issues (such as uninitialized exports or mocking failures), splitting can be disabled. Closes angular#33960 and closes angular#33948
8515226 to
0e23fea
Compare
|
This pull request has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Adds a
splittingoption to the unit-test builder to control code splitting for the test build with the Vitest runner. This option is enabled by default to optimize test bundling performance and memory consumption, avoiding issues during code coverage collection. For Node-based test environments where live ESM bindings across chunk boundaries cause issues (such as uninitialized exports or mocking failures), splitting can be disabled.Closes #33960 and closes #33948