react-hooks-testing-library icon indicating copy to clipboard operation
react-hooks-testing-library copied to clipboard

[Jest] Snapshot serializer not working

Open dkozar opened this issue 3 years ago • 1 comments

Hi,

I have the following snapshot serializer:

image

I've set it up (globally), so Jest uses it when unit tests are running:

image

It works nicely with render() method of @testing-library/react:

image

However, with renderHook(), it seems to not working:

image

It doesn't help if I target the className attribute instead of class:

image

Question: What do I have to do so react-hooks-testing-library uses the snapshot serializer?

dkozar avatar Aug 19 '22 13:08 dkozar

This needs a proper reproduction with no redactions for us to correctly investigate please.

joshuaellis avatar Sep 07 '22 07:09 joshuaellis