import React from 'react';
import { customRender } from 'test-utils';
import NotificationBadge from '.';

describe('<SidebarNotificationBadge />', () => {
  it('should render correctly', () => {
    const { container } = customRender(<NotificationBadge>2</NotificationBadge>);
    const badge = container.firstChild;

    expect(badge).toHaveStyle(`
      color: #FFF;
      background-color: rgb(237, 81, 83);
   `);
  });

  it('should allow to pass any props', () => {
    const { container } = customRender(<NotificationBadge data-foo="bar">2</NotificationBadge>);

    expect(container.querySelector('[data-foo="bar"]')).toBeInTheDocument();
  });
});
