feat: initial setup with WhatsApp CRM apps and sync services
This commit is contained in:
9
apps/whatsapp-sync/tests/__mocks__/qrcode-terminal.js
Normal file
9
apps/whatsapp-sync/tests/__mocks__/qrcode-terminal.js
Normal file
@@ -0,0 +1,9 @@
|
||||
var generate = jest.fn();
|
||||
|
||||
module.exports = {
|
||||
__esModule: true,
|
||||
default: {
|
||||
generate: generate,
|
||||
},
|
||||
generate: generate,
|
||||
};
|
||||
11
apps/whatsapp-sync/tests/__mocks__/whatsapp-web.js
Normal file
11
apps/whatsapp-sync/tests/__mocks__/whatsapp-web.js
Normal file
@@ -0,0 +1,11 @@
|
||||
var MockClient = function() {
|
||||
this.on = jest.fn();
|
||||
this.initialize = jest.fn().mockResolvedValue(undefined);
|
||||
this.getChats = jest.fn().mockResolvedValue([]);
|
||||
this.destroy = jest.fn().mockResolvedValue(undefined);
|
||||
};
|
||||
|
||||
module.exports = {
|
||||
Client: MockClient,
|
||||
LocalAuth: function() {},
|
||||
};
|
||||
Reference in New Issue
Block a user