'use strict';

var _react = require('react');

var _react2 = _interopRequireDefault(_react);

var _reactTestRenderer = require('react-test-renderer');

var _reactTestRenderer2 = _interopRequireDefault(_reactTestRenderer);

var _Header = require('./Header.component');

var _Header2 = _interopRequireDefault(_Header);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

describe('Header', function () {
	it('should render header with one button', function () {
		// given
		var props = {
			headerDefault: [{
				disabled: false,
				label: 'Search for specific values',
				icon: 'talend-search',
				id: 'search',
				onClick: jest.fn() // provided click callback
			}]
		};

		// when
		var wrapper = _reactTestRenderer2.default.create(_react2.default.createElement(_Header2.default, props)).toJSON();

		// then
		expect(wrapper).toMatchSnapshot();
	});
});