actions.spec.jsx 961 B

12345678910111213141516171819202122232425262728293031323334353637
  1. import React from 'react';
  2. import {shallow} from 'sentry-test/enzyme';
  3. import GroupActions from 'app/views/organizationGroupDetails/actions';
  4. import ConfigStore from 'app/stores/configStore';
  5. describe('GroupActions', function() {
  6. beforeEach(function() {
  7. jest.spyOn(ConfigStore, 'get').mockImplementation(() => []);
  8. });
  9. afterEach(function() {});
  10. describe('render()', function() {
  11. it('renders correctly', function() {
  12. const wrapper = shallow(
  13. <GroupActions
  14. group={TestStubs.Group({
  15. id: '1337',
  16. pluginActions: [],
  17. pluginIssues: [],
  18. })}
  19. project={TestStubs.ProjectDetails({
  20. id: '2448',
  21. name: 'project name',
  22. slug: 'project',
  23. })}
  24. organization={TestStubs.Organization({
  25. id: '4660',
  26. slug: 'org',
  27. })}
  28. />
  29. );
  30. expect(wrapper).toMatchSnapshot();
  31. });
  32. });
  33. });