react-native-fast-image/FastImage.test.js

21 lines
473 B
JavaScript
Raw Normal View History

2017-04-17 23:50:22 +00:00
import 'react-native'
import React from 'react'
import renderer from 'react-test-renderer'
import FastImage from './FastImage.js'
test('FastImage renders correctly.', () => {
const tree = renderer.create(
<FastImage
source={{
uri: 'https://facebook.github.io/react/img/logo_og.png',
headers: {
token: 'someToken',
},
priority: FastImage.priority.high,
}}
/>
).toJSON()
expect(tree).toMatchSnapshot()
})