Sha256: 6fc8c4490e64423b9b4134a234f2bdc5e8eea10605ec485b91d26c26cef6a3e9

Contents?: true

Size: 748 Bytes

Versions: 516

Compression:

Stored size: 748 Bytes

Contents

import React from 'react';
import { render, screen } from '../utilities/test-utils';
import Gauge from './_gauge';

beforeEach(() => {
  // Silences error logs within the test suite.
  jest.spyOn(console, 'error');
  jest.spyOn(console, 'warn');
  console.error.mockImplementation(() => {});
  console.warn.mockImplementation(() => {});
});

afterEach(() => {
  console.error.mockRestore();
  console.warn.mockRestore();
});

const testId = 'gauge1';

test('uses exact classname', () => {
  const data = [
    { name: 'Name', value: 45 },
  ]
  render(
    <Gauge
        chartData={data}
        data={{ testid: testId }}
        id='gaugeid'
    />
  );
 
  const kit = screen.getByTestId(testId);
  expect(kit).toHaveClass('pb_gauge_kit');
});

Version data entries

516 entries across 516 versions & 1 rubygems

Version Path
playbook_ui-13.32.0.pre.alpha.PLAY14143288 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143272 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143271 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY1138iconkitaddcolorprop3268 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143267 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.play1416movealiaslogic3266 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143264 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143260 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143255 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14143251 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.play1416movealiaslogic3239 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0.pre.alpha.PLAY14103236 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.play1416movealiaslogic3232 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.PBNTR342navtabbing3231 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.PBNTR342navtabbing3230 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.32.0 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.powercentrainplaybookpt23212 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.PLAY10863204 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.PLAY10863202 app/pb_kits/playbook/pb_gauge/gauge.test.js
playbook_ui-13.31.0.pre.alpha.PLAY882formpillprimaryandneutral3201 app/pb_kits/playbook/pb_gauge/gauge.test.js