aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/organisms/toolbar/toolbar.test.tsx
blob: 72965e8bc7ad270d69c42b8831a8e8cff3494fc8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import { render, screen } from '@test-utils';
import Toolbar from './toolbar';

const nav = [
  { id: 'home-link', href: '/', label: 'Home' },
  { id: 'blog-link', href: '/blog', label: 'Blog' },
  { id: 'cv-link', href: '/cv', label: 'CV' },
  { id: 'contact-link', href: '/contact', label: 'Contact' },
];

describe('Toolbar', () => {
  it('renders a navigation menu', () => {
    render(
      <Toolbar
        ackeeStorageKey="ackee-tracking"
        motionStorageKey="reduced-motion"
        nav={nav}
        searchPage="#"
      />
    );
    expect(screen.getByRole('navigation')).toBeInTheDocument();
  });
});