-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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 transformer signature in babel-jest #7945
Fix transformer signature in babel-jest #7945
Conversation
@@ -47,7 +47,7 @@ | |||
- `[@jest/transform]`: New package extracted from `jest-runtime` ([#7915](https://github.com/facebook/jest/pull/7915)) | |||
- `[babel-plugin-jest-hoist]`: Migrate to TypeScript ([#7898](https://github.com/facebook/jest/pull/7898)) | |||
- `[@jest/core]` Create new package, which is `jest-cli` minus `yargs` and `prompts` ([#7696](https://github.com/facebook/jest/pull/7696)) | |||
- `[@jest/transform]`: Migrate to TypeScript ([#7918](https://github.com/facebook/jest/pull/7918)) | |||
- `[@jest/transform]`: Migrate to TypeScript ([#7918](https://github.com/facebook/jest/pull/7918), [#7945](https://github.com/facebook/jest/pull/7945)) |
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.
This bug was introduced there (unpublished) so we don't need to add noise with an extra entry.
Possible to add a test that verifies the behavior? |
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.
Verified the exported types are still correct (well, more correct since it's not nested), since that was the motivation behind the change
0ece301
to
2e552a3
Compare
2e552a3
to
a913503
Compare
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Summary
#7918 changed the transformer signature to include the own
createTransformer
method, which broke due to how it's used by@jest/transform
. This only attaches the function to the singleton exported by the package.Fixes https://github.com/facebook/jest/pull/7918/files#r258958414
Test plan
Manually tested internally at FB.
Added an e2e test.