()
| 5 | // A fake IPC channel: captures sent messages and lets the test push replies |
| 6 | // back through the registered 'message' listener. |
| 7 | function makeChannel() { |
| 8 | const emitter = new EventEmitter(); |
| 9 | const sent: any[] = []; |
| 10 | const channel = { |
| 11 | sent, |
| 12 | send: (message: any) => { sent.push(message); }, |
| 13 | on: (event: string, listener: (m: any) => void) => emitter.on(event, listener), |
| 14 | reply: (message: any) => emitter.emit('message', message), |
| 15 | }; |
| 16 | return channel; |
| 17 | } |
| 18 | |
| 19 | describe('IpcRunCoordinator', function () { |
| 20 | it('sends a coordinator:shouldRun request and resolves with the reply', async function () { |
no test coverage detected