diff options
Diffstat (limited to 'src/components/molecules/nav/pagination.test.tsx')
| -rw-r--r-- | src/components/molecules/nav/pagination.test.tsx | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/components/molecules/nav/pagination.test.tsx b/src/components/molecules/nav/pagination.test.tsx deleted file mode 100644 index 7662d5f..0000000 --- a/src/components/molecules/nav/pagination.test.tsx +++ /dev/null @@ -1,27 +0,0 @@ -import { describe, expect, it } from '@jest/globals'; -import { render, screen } from '../../../../tests/utils'; -import { Pagination } from './pagination'; - -const total = 50; -const perPage = 10; - -describe('Pagination', () => { - it('renders previous and next page links', () => { - render(<Pagination current={2} total={total} perPage={perPage} />); - expect( - screen.getByRole('link', { name: /Previous page/i }) - ).toBeInTheDocument(); - expect( - screen.getByRole('link', { name: /Next page/i }) - ).toBeInTheDocument(); - }); - - it('renders the page links except for the current one', () => { - render( - <Pagination current={2} siblings={2} total={total} perPage={perPage} /> - ); - expect(screen.getAllByRole('link', { name: /Page / })).toHaveLength( - total / perPage - 1 - ); - }); -}); |
