1
0
mirror of https://github.com/kremalicious/ipfs.git synced 2024-11-22 01:37:07 +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 React from 'react'
import { render, waitFor, screen } from '@testing-library/react' import { render, screen } from '@testing-library/react'
import Home from '../pages' import Home from '../pages'
describe('Home', () => { describe('Home', () => {
it('renders without crashing', async () => { it('renders without crashing', async () => {
render(<Home />) render(<Home />)
await waitFor(() => screen.getAllByTitle('Online').length === 2) await screen.findAllByTitle('Online', undefined, { timeout: 10000 })
expect(screen.getAllByTitle('Online').length).toBe(2) expect(screen.getByText('A public IPFS Gateway')).toBeInTheDocument()
}) })
}) })