Components added. Build issues fixed

This commit is contained in:
Bahadir Sofuoglu 2022-09-14 14:26:01 +03:00
parent 5b66ed1093
commit 18c3721848
344 changed files with 12446 additions and 8758 deletions

View file

@ -1,18 +1,18 @@
import TabPanel from '@/components/tabpanel/TabPanel.vue';
import { mount } from '@vue/test-utils';
import TabView from './TabView.vue';
import TabPanel from '@/components/tabpanel/TabPanel.vue';
describe('TabPanel.vue', () => {
let wrapper;
window.HTMLElement.prototype.scrollIntoView = function() {};
window.HTMLElement.prototype.scrollIntoView = function () {};
beforeEach(() => {
wrapper = mount(TabView, {
global: {
components: {
TabPanel
}
}
},
slots: {
default: `
@ -42,7 +42,7 @@ describe('TabPanel.vue', () => {
it('should change the active item', async () => {
await wrapper.vm.onTabClick({}, 1);
expect(wrapper.findAll('li[role="presentation"]')[1].classes()).toContain('p-highlight');
expect(wrapper.findAll('li[role="presentation"]')[1].classes()).toContain('p-tabview-header');
expect(wrapper.findAll('.p-tabview-panel')[0].attributes().style).toBe('display: none;');
});
});
@ -53,7 +53,7 @@ describe('dynamic tabs', () => {
global: {
components: {
TabPanel
}
}
},
slots: {
default: `
@ -71,4 +71,4 @@ describe('dynamic tabs', () => {
expect(wrapper.findAll('li[role="presentation"]')[0].classes()).toContain('p-highlight');
expect(wrapper.findAll('.p-tabview-panel')[1].attributes().style).toBe('display: none;');
});
});
});