mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-06-17 07:59:17 +08:00
Summary: Per a conversation with TheSavior, in #24538, this adds snapshot tests for all components whose mocks will be addressed in that PR. Shallow and deep snapshots are included. [General] [Added] - Snapshots Pull Request resolved: https://github.com/facebook/react-native/pull/24554 Differential Revision: D15062197 Pulled By: cpojer fbshipit-source-id: 70ddbaa5e6d1d2c0fd1130ab04c458d9c49d0ee8
52 lines
825 B
Plaintext
52 lines
825 B
Plaintext
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
|
|
exports[`<Image /> should render as <Image> when mocked 1`] = `
|
|
<Image
|
|
source={
|
|
Object {
|
|
"uri": "foo-bar.jpg",
|
|
}
|
|
}
|
|
/>
|
|
`;
|
|
|
|
exports[`<Image /> should render as <RCTImageView> when not mocked 1`] = `
|
|
<RCTImageView
|
|
resizeMode="cover"
|
|
source={
|
|
Array [
|
|
Object {
|
|
"uri": "foo-bar.jpg",
|
|
},
|
|
]
|
|
}
|
|
style={
|
|
Object {
|
|
"height": undefined,
|
|
"overflow": "hidden",
|
|
"width": undefined,
|
|
}
|
|
}
|
|
/>
|
|
`;
|
|
|
|
exports[`<Image /> should shallow render as <ForwardRef(Image)> when not mocked 1`] = `
|
|
<ForwardRef(Image)
|
|
source={
|
|
Object {
|
|
"uri": "foo-bar.jpg",
|
|
}
|
|
}
|
|
/>
|
|
`;
|
|
|
|
exports[`<Image /> should shallow render as <Image> when mocked 1`] = `
|
|
<Image
|
|
source={
|
|
Object {
|
|
"uri": "foo-bar.jpg",
|
|
}
|
|
}
|
|
/>
|
|
`;
|