1
0
mirror of https://github.com/kremalicious/blog.git synced 2024-11-25 03:14:01 +01:00
blog/.jest/testRender.ts

13 lines
315 B
TypeScript
Raw Normal View History

2019-05-30 22:59:07 +02:00
import { render } from '@testing-library/react'
2019-10-02 13:35:50 +02:00
import { ReactElement } from 'react'
2019-05-02 21:11:52 +02:00
2020-05-22 14:38:19 +02:00
const testRender = (component: ReactElement): void => {
2019-05-02 21:11:52 +02:00
it('renders without crashing', () => {
const { container } = render(component)
expect(container.firstChild).toBeInTheDocument()
})
}
export default testRender