summaryrefslogtreecommitdiffstats
path: root/src/components/atoms/forms/fieldset.test.tsx
blob: 1d1d2469251b882a1ecad6b8d4d7f29c65bfc18a (plain)
1
2
3
4
5
6
7
8
9
10
11
import { render, screen } from '@test-utils';
import Fieldset from './fieldset';
import { body, legend } from './fieldset.fixture';

describe('Fieldset', () => {
  it('renders a legend and a body', () => {
    render(<Fieldset legend={legend}>{body}</Fieldset>);
    expect(screen.findByRole('group', { name: legend })).toBeTruthy();
    expect(screen.findByText(body)).toBeTruthy();
  });
});