1
0
mirror of https://github.com/kremalicious/ipfs.git synced 2024-11-24 19:00:55 +01:00

test tweak

This commit is contained in:
Matthias Kretschmann 2021-09-12 21:21:18 +02:00
parent 4fabd65c86
commit 06cfdca8e7
Signed by: m
GPG Key ID: 606EEEF3C479A91F

View File

@ -1,11 +1,11 @@
import React from 'react'
import { render, waitFor, screen } from '@testing-library/react'
import { render, screen } from '@testing-library/react'
import Home from '../pages'
describe('Home', () => {
it('renders without crashing', async () => {
render(<Home />)
await waitFor(() => screen.getAllByTitle('Online').length === 2)
expect(screen.getAllByTitle('Online').length).toBe(2)
await screen.findAllByTitle('Online', undefined, { timeout: 10000 })
expect(screen.getByText('A public IPFS Gateway')).toBeInTheDocument()
})
})