feat: Add assign agent option in macro (#5821)

Co-authored-by: fayazara <fayazara@gmail.com>
This commit is contained in:
Tejaswini Chile
2022-11-09 23:22:48 +05:30
committed by GitHub
parent 5febdde938
commit 7352b928da
9 changed files with 66 additions and 4 deletions

View File

@@ -1,7 +1,7 @@
import { createWrapper } from '@vue/test-utils';
import macrosMixin from '../macrosMixin';
import Vue from 'vue';
import { teams, labels } from '../../helper/specs/macrosFixtures';
import { teams, labels, agents } from '../../helper/specs/macrosFixtures';
describe('webhookMixin', () => {
describe('#getEventLabel', () => {
it('returns correct i18n translation:', () => {
@@ -13,6 +13,7 @@ describe('webhookMixin', () => {
return {
teams,
labels,
agents,
};
},
methods: {
@@ -35,6 +36,7 @@ describe('webhookMixin', () => {
expect(wrapper.vm.getDropdownValues('assign_team')).toEqual(teams);
expect(wrapper.vm.getDropdownValues('send_email_to_team')).toEqual(teams);
expect(wrapper.vm.getDropdownValues('add_label')).toEqual(resolvedLabels);
expect(wrapper.vm.getDropdownValues('assign_best_agent')).toEqual(agents);
expect(wrapper.vm.getDropdownValues()).toEqual([]);
});
});