(child: ChildProcess)
| 109 | } |
| 110 | |
| 111 | async function stopViewer(child: ChildProcess): Promise<void> { |
| 112 | if (child.exitCode !== null) return; |
| 113 | await new Promise<void>((resolve) => { |
| 114 | child.once('exit', () => resolve()); |
| 115 | child.kill('SIGTERM'); |
| 116 | // A viewer that ignores SIGTERM must not hang the suite. |
| 117 | setTimeout(() => { |
| 118 | child.kill('SIGKILL'); |
| 119 | resolve(); |
| 120 | }, 5_000).unref(); |
| 121 | }); |
| 122 | } |
| 123 | |
| 124 | describe('codegraph ui — help', () => { |
| 125 | it('reads well and documents the flags', () => { |
no test coverage detected