-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
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
Enhance Jest config error for setupTestFrameworkScriptFile
#3512
Enhance Jest config error for setupTestFrameworkScriptFile
#3512
Conversation
I wasn't aware of the fact that users of c-r-a could just define `src/setupTests.js` and it would be configured with Jest - I nearly ejected before I found a GitHub issue that confirmed this functionality. I thought it might be a nice idea to add it to the error about Jest config overrides to stop others ejecting when they don't need to.
Unless I read the whole message, a quick skim makes it seem like the option is not supported at all and I need to eject. So I don't think this wording makes it much better. :-) Maybe we could tweak the wording? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's tweak the message so it's more obvious what to do on the first glance
👍 sounds good, do you have any thoughts on what it should be? Maybe we should re-organise it to first show my additional message about the setup file; and then have the rest of the message? That way the first thing the user reads is "hey you can use setupTestFile!" rather than "no this doesn't work". What do you think? :) |
Yep |
|
@gaearon thanks for your help :) I've now changed the messages as you suggested. For For any other config that isn't supported: |
…k#3512) * Enhance Jest config error for `setupTestFrameworkScriptFile` I wasn't aware of the fact that users of c-r-a could just define `src/setupTests.js` and it would be configured with Jest - I nearly ejected before I found a GitHub issue that confirmed this functionality. I thought it might be a nice idea to add it to the error about Jest config overrides to stop others ejecting when they don't need to. * Change the order of Jest config errors. * Show different error for `setupTestFrameworkScriptFile` * Tweak the message
…k#3512) * Enhance Jest config error for `setupTestFrameworkScriptFile` I wasn't aware of the fact that users of c-r-a could just define `src/setupTests.js` and it would be configured with Jest - I nearly ejected before I found a GitHub issue that confirmed this functionality. I thought it might be a nice idea to add it to the error about Jest config overrides to stop others ejecting when they don't need to. * Change the order of Jest config errors. * Show different error for `setupTestFrameworkScriptFile` * Tweak the message
I wasn't aware of the fact that users of c-r-a could just define
src/setupTests.js
and it would be configured with Jest - I nearlyejected before I found a GitHub issue that confirmed this functionality.
I thought it might be a nice idea to add it to the error about Jest
config overrides to stop others ejecting when they don't need to.