Files
iptvnator/src/app/services/electron.service.stub.ts
T
2021-10-26 19:55:55 +00:00

24 lines
448 B
TypeScript

export class ElectronServiceStub {
ipcRenderer = {
send: jest.fn(),
on: jest.fn(),
removeAllListeners: jest.fn(),
};
remote = {
process: {
platform: 'linux',
argv: [0, 1],
},
app: {
getVersion: jest.fn(),
}
};
getAppVersion() {
this.remote.app.getVersion();
}
sendIpcEvent() {
this.ipcRenderer.send();
}
}