mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-09-22 16:26:08 +08:00
fix(specs) Use shallow rendering
Now that we have 15.4.2, we don't have to worry about: https://github.com/facebook/react/pull/8097
This commit is contained in:
parent
0638b843b6
commit
6d379efba1
|
@ -1,6 +1,6 @@
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import ReactDOM from 'react-dom'
|
import ReactDOM from 'react-dom'
|
||||||
import {mount} from 'enzyme'
|
import {mount, shallow} from 'enzyme'
|
||||||
import {SelectableTable, EditableTableCell, EditableTable} from 'nylas-component-kit'
|
import {SelectableTable, EditableTableCell, EditableTable} from 'nylas-component-kit'
|
||||||
import {selection, cellProps, tableProps, testDataSource} from '../fixtures/table-data'
|
import {selection, cellProps, tableProps, testDataSource} from '../fixtures/table-data'
|
||||||
|
|
||||||
|
@ -103,7 +103,7 @@ describe('EditableTable Components', function describeBlock() {
|
||||||
|
|
||||||
describe('EditableTable', () => {
|
describe('EditableTable', () => {
|
||||||
function renderTable(props) {
|
function renderTable(props) {
|
||||||
return mount(
|
return shallow(
|
||||||
<EditableTable
|
<EditableTable
|
||||||
{...tableProps}
|
{...tableProps}
|
||||||
{...props}
|
{...props}
|
||||||
|
@ -143,7 +143,7 @@ describe('EditableTable Components', function describeBlock() {
|
||||||
expect(table.prop('extraProps').InputRenderer).toBe(InputRenderer)
|
expect(table.prop('extraProps').InputRenderer).toBe(InputRenderer)
|
||||||
expect(table.prop('other')).toEqual('other')
|
expect(table.prop('other')).toEqual('other')
|
||||||
expect(table.prop('CellRenderer')).toBe(EditableTableCell)
|
expect(table.prop('CellRenderer')).toBe(EditableTableCell)
|
||||||
expect(table.prop('className')).toEqual('editable-table')
|
expect(table.hasClass('editable-table')).toBe(true)
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue