1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-06 00:07:44 +01:00
unleash.unleash/frontend/src/component/menu/Footer/Footer.test.tsx

30 lines
771 B
TypeScript
Raw Normal View History

import React from 'react';
import renderer from 'react-test-renderer';
import { MemoryRouter } from 'react-router-dom';
import Footer from './Footer';
import { ThemeProvider } from 'themes/ThemeProvider';
test('should render DrawerMenu', () => {
const tree = renderer.create(
<ThemeProvider>
<MemoryRouter>
<Footer />
</MemoryRouter>
</ThemeProvider>
);
expect(tree).toMatchSnapshot();
});
test('should render DrawerMenu with "features" selected', () => {
const tree = renderer.create(
<ThemeProvider>
<MemoryRouter initialEntries={['/features']}>
<Footer />
</MemoryRouter>
</ThemeProvider>
);
expect(tree).toMatchSnapshot();
});