-
-
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
Transforms are not ran on snapshotSerializers #3284
Comments
Thanks for reporting! |
Thanks for the suggestion! Could I call |
I don't think that you can call from the |
This is definitely a bug! |
@Daniel15 you can use |
@thymikee Good idea! The way I worked around this was simply by avoiding any code that needed to be transformed (ie. no Flow typing), but using |
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. |
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Snapshot serializers can be configured in the Jest config as follows:
However, Jest does not appear to run the file through the
transform
script. This is blocking me from using Flow in my snapshot serializers, as it throws "SyntaxError: Unexpected identifier" when it tries to execute the file (since it's not being transformed)It looks like
isInternalModule
istrue
in transformAndBuildScript so it's not running the transforms.What is the expected behavior?
Transforms should be ran on these files.
Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.
Internal Facebook www
The text was updated successfully, but these errors were encountered: