import { render } from '../../../utils/theme-render-wrapper';

import { LabelWithHint } from './index';
import mockLabelWithHint from './__mocks__/mockLabelWithHint';

const labelContent = mockLabelWithHint['children'];

describe('<LabelWithHint />', () => {
  it('should render successfully', () => {
    const { baseElement } = render(<LabelWithHint />);
    expect(baseElement).toBeTruthy();
  });

  it('should render label with asterisk', () => {
    const { baseElement } = render(<LabelWithHint required>{labelContent}</LabelWithHint>);
    expect(baseElement).toBeTruthy();
  });

  it('should render label with hint', () => {
    const { baseElement } = render(<LabelWithHint {...mockLabelWithHint} />);
    expect(baseElement).toBeTruthy();
  });
});
