mirror of
https://github.com/grafana/grafana.git
synced 2026-09-05 04:40:13 -05:00
* Search: Adds search to main nav and removes open search click on dashboard name * Updated snapshots * Fixed strict null errors * Fixed type issue
25 lines
482 B
TypeScript
25 lines
482 B
TypeScript
import React from 'react';
|
|
import { mount } from 'enzyme';
|
|
import TopSectionItem from './TopSectionItem';
|
|
|
|
const setup = (propOverrides?: object) => {
|
|
const props = Object.assign(
|
|
{
|
|
link: {
|
|
text: 'Hello',
|
|
url: '/asd',
|
|
},
|
|
},
|
|
propOverrides
|
|
);
|
|
|
|
return mount(<TopSectionItem {...props} />);
|
|
};
|
|
|
|
describe('Render', () => {
|
|
it('should render component', () => {
|
|
const wrapper = setup();
|
|
expect(wrapper).toMatchSnapshot();
|
|
});
|
|
});
|