import { render, screen } from '@testing-library/react'; import DoughnutChart from '../doughnut-chart'; describe('DoughnutChart component', () => { it('should render low percent', () => { const { asFragment } = render( Some content ); // TODO: this should be a visual snapshot eventually expect(asFragment()).toMatchSnapshot(); }); it('should render high percent', () => { const { asFragment } = render( Some content ); // TODO: this should be a visual snapshot eventually expect(asFragment()).toMatchSnapshot(); }); it('should render without content', () => { const { asFragment } = render(); expect(screen.queryByText('60%')).not.toBeNull(); // TODO: this should be a visual snapshot eventually expect(asFragment()).toMatchSnapshot(); }); });