2024-04-01 09:40:21 +03:00

32 lines
625 B
JavaScript

import {test, describe, expect, vi } from 'vitest'
import { mount} from '@vue/test-utils'
import VTabulator from '@molecules/VTabulator/VTabulator.vue';
describe("tests VTabulator component", () => {
vi.mock('tabulator-tables', () => {
const tabulator = vi.fn(() => {
return {
getHtml: () => {
return '<div>test</div>'
}
}
})
return {
__esModule: true,
TabulatorFull: tabulator
}
})
test('exist test of VTabulator', async () => {
const wrapper = mount(VTabulator, {
shallow: true,
})
expect(wrapper.exists()).toBe(true)
})
})