* Sets up listeners for interruption signals * * When one of these signals is caught than raise process.exit() * which enforces `capture-exit` to run registered interruption handlers * * @method setupSignalsTrap
()
| 127 | * @method setupSignalsTrap |
| 128 | */ |
| 129 | function setupSignalsTrap() { |
| 130 | _process.on('SIGINT', exit); |
| 131 | _process.on('SIGTERM', exit); |
| 132 | _process.on('message', onMessage); |
| 133 | |
| 134 | if (isWindowsTTY(_process)) { |
| 135 | trapWindowsSignals(_process); |
| 136 | } |
| 137 | } |
| 138 | |
| 139 | /** |
| 140 | * Removes interruption signal listeners and tears down capture-exit |
no test coverage detected
searching dependent graphs…