projectBadge.spec.jsx 536 B

123456789101112131415
  1. import React from 'react';
  2. import {mount} from 'enzyme';
  3. import ProjectBadge from 'app/components/idBadge/projectBadge';
  4. describe('ProjectBadge', function() {
  5. it('renders with Avatar and team name', function() {
  6. let wrapper = mount(
  7. <ProjectBadge project={TestStubs.Project()} />,
  8. TestStubs.routerContext()
  9. );
  10. expect(wrapper.find('StyledAvatar')).toHaveLength(1);
  11. expect(wrapper.find('PlatformList')).toHaveLength(1);
  12. expect(wrapper.find('BadgeDisplayName').text()).toEqual('project-slug');
  13. });
  14. });