* Create ProcessInfo for testing
(instanceId: string, scriptKey: keyof typeof MOCK_SCRIPTS = 'startup')
| 326 | * Create ProcessInfo for testing |
| 327 | */ |
| 328 | function createTestProcessInfo(instanceId: string, scriptKey: keyof typeof MOCK_SCRIPTS = 'startup'): ProcessInfo { |
| 329 | return { |
| 330 | id: `proc-${instanceId}-${Date.now()}`, |
| 331 | instanceId, |
| 332 | command: 'bun', |
| 333 | args: ['-e', MOCK_SCRIPTS[scriptKey]], |
| 334 | cwd: process.cwd(), |
| 335 | restartCount: 0 |
| 336 | }; |
| 337 | } |
| 338 | |
| 339 | /** |
| 340 | * Create ProcessMonitor with test defaults |