import React from 'react';
import { mount } from 'enzyme';

import MetricsPricingWidget from '.';

describe('MetricsPricingWidget', () => {
  it('displays the <MetricsPricingWidget> element', () => {
    const node = mount(<MetricsPricingWidget />);
    expect(node.getDOMNode().classList).toContain('MetricsPricingWidget');
  });

  it('should render select options if prop labels enabled', () => {
    const props = {
      labels: {
        l1: '',
        l2: '',
      },
    };
    const node = mount(<MetricsPricingWidget {...props} />);
    const option = node.find('option');

    expect(option.exists()).toBe(true);
  });
});
