1 | import React from 'react';
|
2 | import {shallow, mount} from 'enzyme';
|
3 |
|
4 | import Header from './header';
|
5 |
|
6 | describe('Header', () => {
|
7 | const shallowHeader = props => shallow(<Header {...props}/>);
|
8 | const mountHeader = props => mount(<Header {...props}/>);
|
9 |
|
10 | it('should create component', () => {
|
11 | mountHeader().should.have.type(Header);
|
12 | });
|
13 |
|
14 | it('should wrap children with div', () => {
|
15 | shallowHeader().should.have.tagName('div');
|
16 | });
|
17 |
|
18 | it('should use passed className', () => {
|
19 | shallowHeader({className: 'test-class'}).should.have.className('test-class');
|
20 | });
|
21 |
|
22 | // TODO Add more tests
|
23 | });
|