import { render } from '@react-email/render'; import { Img } from './index.js'; describe(' component', () => { it('passes style and other props correctly', async () => { const style = { backgroundColor: 'red', border: 'solid 1px black' }; const html = await render( Cat, ); expect(html).toContain('background-color:red'); expect(html).toContain('border:solid 1px black'); expect(html).toContain('data-testid="img-test"'); }); it('renders correctly', async () => { const actualOutput = await render( Cat, ); expect(actualOutput).toMatchInlineSnapshot( `"Cat"`, ); }); });