Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Feat/load referenced config from packagejson #14044
Feat/load referenced config from packagejson #14044
Changes from 20 commits
3210659
398dc06
d0fd07d
2225077
0948287
b6a58ff
c539a99
0a21122
111ce11
a06ed19
6fa9dde
26f5427
b3379dc
dd4238b
517e302
8f326a2
e50fda7
1f3b8f0
94e23f2
8fcfa68
d174794
a551494
fce78ca
6149986
ddbb1c8
af8716b
78c0ba5
b552e19
ab6d71f
00167af
886420c
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
if the path provided isn't a file, we should throw an error
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.
In that case, when jest key could not be resolved as a valid file path, the package.Json is assumed. That because jest key can be a path or a config object, so i need to allow that function to return for a second flow option.
I did a new test case to avoid future issues for those who changes that code. It makes sense?
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.
My point is that if you in your config define
"jest": "./some-path"
(i.e. it is a string), and the path it resolves to is not a file, then Jest should error. Not ignore the entry.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.
Nice, guess i understood the point: if path is not a config object and it is an string there is no option to it to not be a file, be a file or throw an error. Working on it for the next push commit
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.
yeah, exactly 👍