diff options
Diffstat (limited to 'src/components/atoms/modal/modal.test.tsx')
| -rw-r--r-- | src/components/atoms/modal/modal.test.tsx | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/components/atoms/modal/modal.test.tsx b/src/components/atoms/modal/modal.test.tsx deleted file mode 100644 index dfa4a88..0000000 --- a/src/components/atoms/modal/modal.test.tsx +++ /dev/null @@ -1,26 +0,0 @@ -import { describe, expect, it } from '@jest/globals'; -import { render, screen as rtlScreen } from '../../../../tests/utils'; -import { Heading } from '../heading'; -import { Modal } from './modal'; - -const title = 'A custom title'; -const children = - 'Labore ullam delectus sit modi quam dolores. Ratione id sint aliquid facilis ipsum. Unde necessitatibus provident minus.'; - -describe('Modal', () => { - it('renders a title', () => { - const level = 2; - - render( - <Modal heading={<Heading level={level}>{title}</Heading>}> - {children} - </Modal> - ); - expect(rtlScreen.getByRole('heading', { level })).toHaveTextContent(title); - }); - - it('renders the modal body', () => { - render(<Modal>{children}</Modal>); - expect(rtlScreen.getByText(children)).toBeInTheDocument(); - }); -}); |
