import { mount } from '@vue/test-utils'; import { Icon } from '../../dist/offline'; const iconData = { body: '', width: 24, height: 24, }; describe('Creating component', () => { test('with wrapper', () => { const Wrapper = { components: { Icon }, template: ``, data() { return { icon: iconData, }; }, }; const wrapper = mount(Wrapper, {}); expect(wrapper.html().replace(/\s*\n\s*/g, '')).toEqual( '' ); }); test('without wrapper', () => { const wrapper = mount(Icon, { props: { icon: iconData, }, }); expect(wrapper.html().replace(/\s*\n\s*/g, '')).toEqual( '' ); }); });