'use strict';

var _react = require('react');

var _react2 = _interopRequireDefault(_react);

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

var _reactTestRenderer2 = _interopRequireDefault(_reactTestRenderer);

var _index = require('./index');

var _index2 = _interopRequireDefault(_index);

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

test('SortableList renders correctly', function () {
  var tree = _reactTestRenderer2.default.create(_react2.default.createElement(
    _index2.default,
    {
      list: [{ _id: 1, value: '1' }, { _id: 2, value: '2' }, { _id: 3, value: '3' }],
      keyProp: '_id',
      listName: 'list',
      onChange: function onChange(items) {
        return console.log('SortableList [onChange] : ', items);
      }
    },
    function (item) {
      return _react2.default.createElement(
        'div',
        null,
        item.value
      );
    }
  )).toJSON();
  expect(tree).toMatchSnapshot();
}); // eslint-disable-line import/no-extraneous-dependencies

/* eslint-disable no-console */