Remove NetworkHealthIndicator test that was shit

This commit is contained in:
lee-at-zoo-corp
2025-04-03 18:29:27 -04:00
parent 496522e27d
commit 682fa50c1a

View File

@ -1,31 +0,0 @@
import { fireEvent, render, screen } from '@testing-library/react'
import { BrowserRouter } from 'react-router-dom'
import {
NETWORK_HEALTH_TEXT,
NetworkHealthIndicator,
} from '@src/components/NetworkHealthIndicator'
import { NetworkHealthState } from '@src/hooks/useNetworkStatus'
function TestWrap({ children }: { children: React.ReactNode }) {
// wrap in router and xState context
return <BrowserRouter>{children}</BrowserRouter>
}
// Our Playwright tests for this are much more comprehensive.
describe('NetworkHealthIndicator tests', () => {
test('Renders the network indicator', () => {
render(
<TestWrap>
<NetworkHealthIndicator />
</TestWrap>
)
fireEvent.click(screen.getByTestId('network-toggle'))
// Starts as disconnected
expect(screen.getByTestId('network')).toHaveTextContent(
NETWORK_HEALTH_TEXT[NetworkHealthState.Disconnected]
)
})
})