Files
manja_dev_ui/tests/unit/views/base/Table.spec.js
T
2020-07-16 12:31:55 +02:00

25 lines
625 B
JavaScript

import Vue from 'vue'
import { mount, shallowMount } from '@vue/test-utils';
import CoreuiVue from '@coreui/vue'
import Table from '@/views/base/Table'
Vue.use(CoreuiVue)
describe('Table.vue', () => {
it('has a name', () => {
expect(Table.name).toBe('Table')
})
it('is Vue instance', () => {
const wrapper = mount(Table)
expect(wrapper.vm).toBeTruthy()
})
it('is Table', () => {
const wrapper = mount(Table)
expect(wrapper.findComponent(Table)).toBeTruthy()
})
test('renders correctly', () => {
const wrapper = shallowMount(Table)
expect(wrapper.element).toMatchSnapshot()
})
})