import React from 'react'
import { render } from '@testing-library/react-native'
import { ReplyPreview } from '../components/ReplyPreview'
import { ReplyMessage } from '../Models'
const replyMessage: ReplyMessage = {
_id: 'reply-1',
text: 'Original message to reply to',
user: {
_id: 2,
name: 'John Doe',
},
}
it('should render and compare with snapshot', () => {
const { toJSON } = render(
{}}
/>
)
expect(toJSON()).toMatchSnapshot()
})
it('should render with image and compare with snapshot', () => {
const replyWithImage: ReplyMessage = {
...replyMessage,
image: 'https://example.com/image.jpg',
}
const { toJSON } = render(
{}}
/>
)
expect(toJSON()).toMatchSnapshot()
})