()
| 252 | } |
| 253 | |
| 254 | function killProcessAndCleanup() { |
| 255 | killProcess(); |
| 256 | options.log(`[pid=${spawnedProcess.pid || 'N/A'}] starting temporary directories cleanup`); |
| 257 | for (const dir of options.tempDirectories) { |
| 258 | try { |
| 259 | fs.rmSync(dir, { force: true, recursive: true, maxRetries: 5 }); |
| 260 | } catch (e) { |
| 261 | options.log(`[pid=${spawnedProcess.pid || 'N/A'}] exception while removing ${dir}: ${e}`); |
| 262 | } |
| 263 | } |
| 264 | options.log(`[pid=${spawnedProcess.pid || 'N/A'}] finished temporary directories cleanup`); |
| 265 | } |
| 266 | |
| 267 | function killAndWait() { |
| 268 | killProcess(); |
nothing calls this directly
no test coverage detected
searching dependent graphs…