This commit is contained in:
parent
249646236a
commit
2ee0c93e24
|
@ -39,7 +39,7 @@ describe('ticket setWeight()', () => {
|
|||
expect(ticket.weight).toEqual(weight);
|
||||
});
|
||||
|
||||
it('should throw an error if the user does not have enough privileges', async() => {
|
||||
it('should throw an error if the user is not allocated to the same department', async() => {
|
||||
ctx.req.accessToken.userId = employeeId;
|
||||
try {
|
||||
const ticketId = 10;
|
||||
|
@ -47,7 +47,7 @@ describe('ticket setWeight()', () => {
|
|||
|
||||
await models.Ticket.setWeight(ctx, ticketId, weight, opts);
|
||||
} catch (e) {
|
||||
expect(e.message).toEqual('You don\'t have enough privileges');
|
||||
expect(e.message).toEqual('This ticket is not allocated to your department');
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue