Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
describe('Integration | Component | Book information Card', () => {
it('Vérification du snapshot avec un livre', async () => {
const book = new BookDetails('title', true)
const { asFragment } = render(<BookInformationCard book={ book }/>)
await waitFor(() => {
expect(asFragment()).toMatchSnapshot()
})
})
it('Vérification du snapshot sans livre', async () => {
const { asFragment } = render(<BookInformationCard book={ null }/>)
await waitFor(() => {
expect(asFragment()).toMatchSnapshot()
})
})
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment