"use strict";

var _react = _interopRequireDefault(require("react"));

var _enzyme = require("enzyme");

var _statefulMenu = _interopRequireDefault(require("../stateful-menu"));

var _statefulContainer = _interopRequireDefault(require("../stateful-container"));

var _menu = _interopRequireDefault(require("../menu"));

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

/*
Copyright (c) 2018 Uber Technologies, Inc.

This source code is licensed under the MIT license found in the
LICENSE file in the root directory of this source tree.
*/
describe('Menu StatefulMenu', function () {
  test('renders with props', function () {
    var props = {
      items: [{
        label: 'item1'
      }, {
        label: 'item2'
      }],
      getItemLabel: function getItemLabel(item) {
        return item.label;
      }
    };
    var component = (0, _enzyme.mount)(_react.default.createElement(_statefulMenu.default, props));
    expect(component.find(_statefulContainer.default).length).toBe(1);
    expect(component.find(_menu.default).length).toBe(1);
  });
});