facebook / create-react-app

Set up a modern web app by running one command.
https://create-react-app.dev
MIT License
102.71k stars 26.85k forks source link

include support for jest-runner-groups #8715

Open timrobinson33 opened 4 years ago

timrobinson33 commented 4 years ago

Is your proposal related to a problem?

I'd like to categorize my jest tests so that I can run only a certain subset of them.

Describe the solution you'd like

There is already a package to facilitate this called jest-runner-groups, but I cannot use this in conjunction with create-react-app since it needs me to set the "runner" option which is not currently supported.

Describe alternatives you've considered

the other alternative is to use --testNamePattern which does work but is more cumbersome to use as I need to include a unique word in the title of every test, or surround them in a describe block

Additional context

(Write your answer here.)

mAAdhaTTah commented 4 years ago

The runner option isn't supported via configuration but can be provided via CLI flag. Not ideal, but it is available.

timrobinson33 commented 4 years ago

OK I've finally got this working. If anyone else wants to know how, see https://github.com/eugene-manuilov/jest-runner-groups/issues/7

I'm happy with this workaround so you can close this issue unless you think it's something that should be included in create-react-ap