import React__default from 'react';
import { cleanup, render, screen, fireEvent } from '@testing-library/react';
import '@testing-library/jest-dom/extend-expect';
import Button from '../index.js';
import '../../defineProperty-CEd-kZQW.js';
import '../../extends-C4cduGrv.js';
import '../../objectWithoutProperties-TXwlfNxG.js';
import 'prop-types';
import '@reach/visually-hidden';
import '../../ck-icon/index.js';
import 'classnames';
import '../../ck-icon/assets/icon-map/index.js';
import '../../icon/index.js';
import '@fortawesome/react-fontawesome';
import '../../icon/icons.js';
import '../../icon/library.js';
import '@fortawesome/fontawesome-svg-core';
import '@fortawesome/pro-solid-svg-icons';
import '@fortawesome/pro-light-svg-icons';
import '@fortawesome/free-brands-svg-icons';
import '../../slicedToArray-BB-AwwkK.js';
import '../button-group.js';

afterEach(cleanup);
describe("Button", function () {
  it("renders", function () {
    render( /*#__PURE__*/React__default.createElement(Button, null, "Button"));
    expect(screen.getByText("Button")).toBeInTheDocument();
  });
  it("has cursor-pointer when enabled", function () {
    render( /*#__PURE__*/React__default.createElement(Button, {
      disabled: false
    }, "Button"));
    var button = screen.getByText("Button");
    fireEvent.mouseOver(button);
    expect(button).toHaveClass("cursor-pointer");
  });
  it("has cursor-default when disabled", function () {
    render( /*#__PURE__*/React__default.createElement(Button, {
      disabled: true
    }, "Button"));
    var button = screen.getByText("Button");
    fireEvent.mouseOver(button);
    expect(button).toHaveClass("cursor-default");
  });
  it("has cursor-default when disabled is added but not explicitly set", function () {
    render( /*#__PURE__*/React__default.createElement(Button, {
      disabled: true
    }, "Button"));
    var button = screen.getByText("Button");
    fireEvent.mouseOver(button);
    expect(button).toHaveClass("cursor-default");
  });
});
