"use strict";

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

var _enzyme = require("enzyme");

var _NotebookPreview = _interopRequireDefault(require("./NotebookPreview"));

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

describe("NotebookPreview", function () {
  it("should render NotebookPreview", function () {
    var wrapper = (0, _enzyme.mount)(_react["default"].createElement(_NotebookPreview["default"], null));
    expect(wrapper.find("NotebookPreview")).to.have.length(1);
    expect(wrapper.find("NotebookPreview").children()).to.have.length(1);
  });
  it("should have the appropriate default message", function () {
    var defaultMessage = "See the data science notebook";
    var wrapper = (0, _enzyme.mount)(_react["default"].createElement(_NotebookPreview["default"], null));
    expect(wrapper.find("NotebookPreview").children().first().text()).to.eql(" ".concat(defaultMessage));
  });
  it("should have the appropriate prop message", function () {
    var messageProp = "Oooh! Dynamic text";
    var wrapper = (0, _enzyme.mount)(_react["default"].createElement(_NotebookPreview["default"], {
      message: messageProp
    }));
    expect(wrapper.find("NotebookPreview").children().first().text()).to.eql(" ".concat(messageProp));
  });
});