Files
react-native/Libraries/Modal/__tests__/__snapshots__/Modal-test.js.snap
T
Rick Hanlon 4b935ae95f Correctly mock all components by setting the displayName
Summary:
In the next react sync we removed the `displayName` from forwardRef and useMemo components ([PR here](https://github.com/facebook/react/pull/18495 )).

This means we need to manually add the displayName in the mock.

Changelog: [General] [Fixed] Fix test renderer mocks to use the displayName more often.

Reviewed By: TheSavior

Differential Revision: D22775470

fbshipit-source-id: 1390dc325e34f7ccea32bbdf1c6a8f6efea3a080
2020-07-28 13:09:06 -07:00

81 lines
1.4 KiB
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`<Modal /> should render as <Modal> when mocked 1`] = `
<Modal
hardwareAccelerated={false}
visible={true}
>
<View />
</Modal>
`;
exports[`<Modal /> should render as <RCTModalHostView> when not mocked 1`] = `
<RCTModalHostView
animationType="none"
hardwareAccelerated={false}
identifier={1}
onStartShouldSetResponder={[Function]}
presentationStyle="fullScreen"
style={
Object {
"position": "absolute",
}
}
>
<View
collapsable={false}
style={
Array [
Object {
"flex": 1,
"left": 0,
"top": 0,
},
Object {
"backgroundColor": "white",
},
]
}
>
<View
pointerEvents="box-none"
style={
Object {
"flex": 1,
}
}
>
<View
collapsable={true}
pointerEvents="box-none"
style={
Object {
"flex": 1,
}
}
>
<View />
</View>
</View>
</View>
</RCTModalHostView>
`;
exports[`<Modal /> should shallow render as <Modal> when mocked 1`] = `
<Modal
hardwareAccelerated={false}
visible={true}
>
<View />
</Modal>
`;
exports[`<Modal /> should shallow render as <Modal> when not mocked 1`] = `
<Modal
hardwareAccelerated={false}
visible={true}
>
<View />
</Modal>
`;