aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/atoms/layout/main.test.tsx
blob: 58dc660928c838dac18c9f7de74f0b6cd755f273 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
import { describe, expect, it } from '@jest/globals';
import { render, screen } from '../../../../tests/utils';
import { Main } from './main';

const id = 'main';
const children = 'The main content.';

describe('Main', () => {
  it('renders the content of main element', () => {
    render(<Main id={id}>{children}</Main>);
    expect(screen.getByRole('main')).toHaveTextContent(children);
  });
});