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

Allow specifying --runInBand in config file #6709

Closed
felipeochoa opened this issue Jul 17, 2018 · 4 comments
Closed

Allow specifying --runInBand in config file #6709

felipeochoa opened this issue Jul 17, 2018 · 4 comments

Comments

@felipeochoa
Copy link
Contributor

🚀 Feature Proposal

Add an option to the file-based config equivalent to setting --runInBand on the CLI

Motivation

For node projects that have external dependencies (e.g., sqlite, filesystem, shared libs) that can't (easily) be made safe to access in parallel, it would be nice to always force jest to run sequentially.

Example

// jest.config.js
module.exports = {
  runInBand: true,
}

Pitch

The main alternative solution would be to add the flag to a package script (e.g., "test": "jest --runInBand"). This requires configuring all editor plugins (like this one) which duplicates these settings and makes it harder to have node and broweser packages together. In my own setup, it's easier to always run jest with --runInBand, but that's unnecessarily slow many times.

@tokland
Copy link

tokland commented Jul 20, 2018

Related: #3215

@felipeochoa
Copy link
Contributor Author

Woops didn't find that originally, thanks

@rickhanlonii
Copy link
Member

rickhanlonii commented Jul 20, 2018

Closing as a dupe of #3215 👌

@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants