Add snapshot tests

This commit is contained in:
Jeremy Nagel
2018-08-13 16:50:43 +10:00
parent 03389aece0
commit 96d33a60ba
3 changed files with 30 additions and 1 deletions

View File

@@ -0,0 +1,14 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`<SelectionCell /> render should render component correctly 1`] = `
<td
onClick={[Function]}
>
<input
checked={true}
className=""
onChange={[Function]}
type="checkbox"
/>
</td>
`;

View File

@@ -0,0 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`<CheckBox /> render should render component correctly 1`] = `
<input
checked={true}
onChange={[Function]}
type="checkbox"
/>
`;

View File

@@ -170,7 +170,13 @@ describe('<SelectionCell />', () => {
describe('when disabled prop give as true', () => {
beforeEach(() => {
wrapper = shallowWithContext(
<SelectionCell rowKey={ 1 } mode={ mode } rowIndex={ rowIndex } selected={ selected } disabled />,
<SelectionCell
rowKey={ 1 }
mode={ mode }
rowIndex={ rowIndex }
selected={ selected }
disabled
/>,
{ bootstrap4: false }
);
});