import React from 'react' ; import { shallow } from 'enzyme' ; import { StatusTable } from './status_table' ; const state = { id : 'green' , uiColor : 'secondary' , message : 'Ready' , title : 'green' , } ; describe ( 'StatusTable' , ( ) => { it ( 'renders when statuses is provided' , ( ) => { const component = shallow ( < StatusTable statuses = { [ { id : 'plugin:1' , state } ] } / > ) ; expect ( component ) . toMatchSnapshot ( ) ; } ) ; it ( 'renders when statuses is not provided' , ( ) => { const component = shallow ( < StatusTable />); expect ( component . isEmptyRender ( ) ) . toBe ( true ) ; } ) ; } ) ;