Commit 9cb03fe
committed
fix(@angular/build): warn about performance of test.exclude in vitest configuration
When a user specifies `test.exclude` inside their `vitest.config.ts`, the tests are correctly excluded during Vitest's execution phase. However, because the Angular CLI extracts test files earlier in the process using its own `exclude` builder option, those skipped tests are still unnecessarily compiled by esbuild in-memory.
This adds a warning to explicitly notify developers of this hidden build overhead and suggests using the Angular CLI `exclude` option instead to improve performance.1 parent 1a8376b commit 9cb03fe
File tree
2 files changed
+40
-0
lines changed- packages/angular/build/src/builders/unit-test
- runners/vitest
- tests/behavior
2 files changed
+40
-0
lines changedLines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
109 | 117 | | |
110 | 118 | | |
111 | 119 | | |
| |||
Lines changed: 32 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
348 | 348 | | |
349 | 349 | | |
350 | 350 | | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
351 | 383 | | |
352 | 384 | | |
353 | 385 | | |
| |||
0 commit comments