Update OrderList.spec.js
parent
3d17b07c9e
commit
7aae278a2c
|
@ -117,11 +117,13 @@ describe('OrderList.vue', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should select item', async () => {
|
it('should select item', async () => {
|
||||||
expect(wrapper.find('.p-orderlist.p-component').exists()).toBe(true);
|
|
||||||
await wrapper.vm.onItemClick({}, wrapper.vm.modelValue[0], 0);
|
await wrapper.vm.onItemClick({}, wrapper.vm.modelValue[0], 0);
|
||||||
// expect(wrapper.emitted()['update:selection'][0]).toEqual([[wrapper.vm.modelValue[0]]]);
|
|
||||||
// await wrapper.setProps({ selection: [wrapper.vm.modelValue[0]] });
|
expect(wrapper.emitted()['update:selection'][0]).toEqual([[wrapper.vm.modelValue[0]]]);
|
||||||
// expect(wrapper.findAll('li.p-orderlist-item')[0].classes()).toContain('p-highlight');
|
|
||||||
|
await wrapper.setProps({ selection: [wrapper.vm.modelValue[0]] });
|
||||||
|
|
||||||
|
expect(wrapper.findAll('li.p-orderlist-item')[0].classes()).toContain('p-highlight');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should slot works', () => {
|
it('should slot works', () => {
|
||||||
|
|
Loading…
Reference in New Issue