Commit 58094faa by Peter Holmberg

test and minor fix on mapping row

parent 219da09f
import React from 'react';
import { shallow } from 'enzyme';
import { FormGroup, Props } from './FormGroup';
const setup = (propOverrides?: object) => {
const props: Props = {
label: 'Test',
labelWidth: 11,
inputProps: {
value: 10,
onChange: jest.fn(),
},
};
Object.assign(props, propOverrides);
return shallow(<FormGroup {...props} />);
};
describe('Render', () => {
it('should render component', () => {
const wrapper = setup();
expect(wrapper).toMatchSnapshot();
});
});
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`Render should render component 1`] = `
<div
className="gf-form"
>
<Component
width={11}
>
Test
</Component>
<input
className="gf-form-input width-12"
onChange={[MockFunction]}
type="text"
value={10}
/>
</div>
`;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment