UNPKG

svg-loaders-react

Version:

React implementation of the SVG Loaders library by Sam Herbert

15 lines (12 loc) 412 B
import React from 'react'; import { shallow, mount } from 'enzyme'; import { Hearts } from '../src/svg-loader-components/hearts'; describe('Test <Hearts />', () => { it('renders without crashing', () => { shallow(<Hearts />); }); it('viewBox property is defined', () => { const HeartsComponent = mount(<Hearts />).find('svg'); expect(HeartsComponent.prop('viewBox')).toBeDefined(); }); });