gradido/admin/src/components/FigureQrCode.spec.js
2022-06-08 21:14:34 +02:00

31 lines
643 B
JavaScript

import { mount } from '@vue/test-utils'
import FigureQrCode from './FigureQrCode.vue'
const localVue = global.localVue
const propsData = {
link: '',
}
describe('FigureQrCode', () => {
let wrapper
const Wrapper = () => {
return mount(FigureQrCode, { localVue, propsData })
}
describe('mount', () => {
beforeEach(() => {
wrapper = Wrapper()
})
it('renders the Div Element ".figure-qr-code"', () => {
expect(wrapper.find('div.figure-qr-code').exists()).toBe(true)
})
it('renders the QRCanvas Element ".canvas"', () => {
expect(wrapper.find('.canvas').exists()).toBe(true)
})
})
})