Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(browser): disable fileParallelism by default on browser pool #5528

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/vitest/src/node/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,8 @@ export function resolveConfig(
if (resolved.minWorkers)
resolved.minWorkers = Number(resolved.minWorkers)

// run benchmark sequentially by default
resolved.fileParallelism ??= mode !== 'benchmark'
// browser pool and benchmark are sequential by default
resolved.fileParallelism ??= resolved.pool !== 'browser' && mode !== 'benchmark'
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

resolved.pool is always threads here, so this isn't right...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's also possible to override pool with poolMatchGlobs.

The easiest solution here would be to set resolved.browser.fileParallelism before we override resolved.fileParallelism

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, that sounds good. Updated in ee772d1


if (!resolved.fileParallelism) {
// ignore user config, parallelism cannot be implemented without limiting workers
Expand Down