theforeman/foreman

View on GitHub
webpack/assets/javascripts/react_app/components/common/table/components/__tests__/DeleteButton.test.js

Summary

Maintainability
A
0 mins
Test Coverage
import { testComponentSnapshotsWithFixtures } from '@theforeman/test';
import DeleteButton from '../DeleteButton';

const baseProps = {
  id: 1,
  name: 'KVM',
  controller: 'models',
  onClick: () => {},
};

const fixtures = {
  'should render delete button on active': {
    active: true,
    ...baseProps,
  },
  'should render nothing on inactive': baseProps,
};

describe('DeleteButton', () => {
  testComponentSnapshotsWithFixtures(DeleteButton, fixtures);
});