Files
react-native/packages/react-native-test-renderer
Jack Pope 41045a1486 Refactor toJSON (#42828)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/42828

Updates to toJSON:
- return object tree instead of formatted snapshot string. Applying the `'react.test.json'` symbol lets Jest do the formatting work for us
- Source props from `pendingProps` on `instanceHandle`. This adds props such as `pointerEvents` and `style` which were present on RTR's snapshots but don't get included in the node's `props` collection
- Render text node as text value, instead of RCTRawText like `<RCTRawText text="Hello" />`

Changelog: [internal]

Reviewed By: kassens

Differential Revision: D53321821

fbshipit-source-id: 033637b9152441c318c9c797aa9223ff15768873
2024-02-02 14:34:43 -08:00
..
2024-02-02 14:34:43 -08:00