-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Description
Command
test
Is this a regression?
- Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was
Just before cf47d15
Description
When using --debug option with Vitest, it produces the following error: AggregateError: Failed to initialize projects. There were errors during projects setup. See below for more details.
This happens because Vitest checks that there is a chromium browser in the instances list: https://github.com/vitest-dev/vitest/blob/9e24a59f2c9dbd44439e38968c6c6eb216ebd50a/packages/vitest/src/node/config/resolveConfig.ts#L850C17-L850C37
but during this check it verifies that the project is not filtered out.
Problem is that the project option is set to the value of projectName which does not match the instance name ${projectName} (chromium).
It would be also nice to fail gracefully when debug is set and there is no chromium browser.
(By the way, the error is truncated when using the CLI. In plain Vitest, the aggregated errors are logged)
Minimal Reproduction
ng test --debug
Exception or Error
AggregateError: Failed to initialize projects. There were errors during projects setup. See below for more details
Your Environment
Build of cf47d15.
Anything else relevant?
No response