diff --git a/modules/claim/back/methods/claim/regularizeClaim.js b/modules/claim/back/methods/claim/regularizeClaim.js index a56d57e9b4..ea1a7a8131 100644 --- a/modules/claim/back/methods/claim/regularizeClaim.js +++ b/modules/claim/back/methods/claim/regularizeClaim.js @@ -41,7 +41,7 @@ module.exports = Self => { relation: 'claimDestination', fields: ['addressFk'] }, - where: {claimFk: claimFk} + where: {claimFk} }, myOptions); for (let claimEnd of claimEnds) { diff --git a/modules/claim/back/methods/claim/specs/regularizeClaim.spec.js b/modules/claim/back/methods/claim/specs/regularizeClaim.spec.js index a1578ac7f8..c3fe7daa6f 100644 --- a/modules/claim/back/methods/claim/specs/regularizeClaim.spec.js +++ b/modules/claim/back/methods/claim/specs/regularizeClaim.spec.js @@ -55,7 +55,7 @@ describe('claim regularizeClaim()', () => { expect(trashTicket.addressFk).toEqual(trashAddress); expect(claimBefore.claimStateFk).toEqual(pendentState); expect(claimAfter.claimStateFk).toEqual(resolvedState); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jvp_equipo', 'Trash'); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es5_equipo', 'Trash'); expect(chatModel.send).toHaveBeenCalledTimes(4); await tx.rollback(); @@ -80,7 +80,7 @@ describe('claim regularizeClaim()', () => { await models.Claim.regularizeClaim(ctx, claimId, options); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jvp_equipo', 'Bueno'); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es5_equipo', 'Bueno'); expect(chatModel.send).toHaveBeenCalledTimes(4); await tx.rollback(); @@ -105,7 +105,7 @@ describe('claim regularizeClaim()', () => { await models.Claim.regularizeClaim(ctx, claimId, options); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jvp_equipo', 'Bueno'); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es5_equipo', 'Bueno'); expect(chatModel.send).toHaveBeenCalledTimes(4); await tx.rollback(); diff --git a/modules/client/back/models/specs/client.spec.js b/modules/client/back/models/specs/client.spec.js index 3b194e7219..af0e19c7b1 100644 --- a/modules/client/back/models/specs/client.spec.js +++ b/modules/client/back/models/specs/client.spec.js @@ -16,8 +16,8 @@ describe('Client Model', () => { const ctx = {req: activeCtx}; const chatModel = models.Chat; const instance = {id: 1101, name: 'Bruce Banner'}; - const previousDepartmetnId = 80; // jvp_equipo - const currentDepartmetnId = 94; // jes_equipo + const previousDepartmetnId = 80; // es5_equipo + const currentDepartmetnId = 94; // es2_equipo beforeEach(() => { spyOn(LoopBackContext, 'getCurrentContext').and.returnValue({ @@ -31,8 +31,8 @@ describe('Client Model', () => { await models.Client.notifyAssignment(instance, previousDepartmetnId, currentDepartmetnId); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jvp_equipo', `Client assignment has changed`); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jes_equipo', `Client assignment has changed`); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es5_equipo', `Client assignment has changed`); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es2_equipo', `Client assignment has changed`); }); it('should call to the Chat send() method for the previous worker', async() => { @@ -40,7 +40,7 @@ describe('Client Model', () => { await models.Client.notifyAssignment(instance, null, currentDepartmetnId); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jes_equipo', `Client assignment has changed`); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es2_equipo', `Client assignment has changed`); }); it('should call to the Chat send() method for the current worker', async() => { @@ -48,7 +48,7 @@ describe('Client Model', () => { await models.Client.notifyAssignment(instance, previousDepartmetnId, null); - expect(chatModel.send).toHaveBeenCalledWith(ctx, '@jvp_equipo', `Client assignment has changed`); + expect(chatModel.send).toHaveBeenCalledWith(ctx, '@es5_equipo', `Client assignment has changed`); }); });