You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
569 B
26 lines
569 B
import React from 'react';
|
|
import { shallow } from 'enzyme';
|
|
import { ApiKeysAddedModal, Props } from './ApiKeysAddedModal';
|
|
|
|
const setup = (propOverrides?: object) => {
|
|
const props: Props = {
|
|
onDismiss: jest.fn(),
|
|
apiKey: 'api key test',
|
|
rootPath: 'test/path',
|
|
};
|
|
|
|
Object.assign(props, propOverrides);
|
|
|
|
const wrapper = shallow(<ApiKeysAddedModal {...props} />);
|
|
|
|
return {
|
|
wrapper,
|
|
};
|
|
};
|
|
|
|
describe('Render', () => {
|
|
it('should render component', () => {
|
|
const { wrapper } = setup();
|
|
expect(wrapper).toMatchSnapshot();
|
|
});
|
|
});
|
|
|