my unique test
import VueI18n from 'vue-i18n'
import Vuex from "vuex"
import iView from 'view-design'
import {mount,createLocalVue} from '@vue/test-utils'
// @ts-ignore
import FormAccountName from '@/views/forms/FormAccountName/FormAccountName'
const localVue = createLocalVue()
localVue.use(Vuex)
localVue.use(iView)
localVue.use(VueI18n)
describe('test description',()=>{
test('test example',async ()=>{
const wrapper = mount(FormAccountName,{
localVue,
mocks: {
$t: () => 'this is a label',
formItems: {
name: '<a>'
}
},
})
expect(wrapper).toMatchSnapshot()
})
})
unique error message
The snapshot was generated successfully, but an unexpected error occurred
[Vue warn]: Error in nextTick: "TypeError: document.createRange is not a function"
found in
---> <Tooltip>
<ErrorTooltipTs>
<ValidationProvider>
<FormRow>
<ValidationObserver>
<FormWrapper>
<FormAccountNameUpdateTs>
<Root>
Even though I initialized the iView tag, an error occurred. I am unsure of what went wrong. Can someone offer assistance?