(server: ServerType)
| 39 | }); |
| 40 | |
| 41 | function boundAddress(server: ServerType): string { |
| 42 | const addr = server.address(); |
| 43 | if (addr === null || typeof addr === "string") { |
| 44 | throw new Error(`expected an AddressInfo, got ${JSON.stringify(addr)}`); |
| 45 | } |
| 46 | return addr.address; |
| 47 | } |
| 48 | |
| 49 | async function startConfigProbeServer(payload: Record<string, unknown>): Promise<number> { |
| 50 | const server = createHttpServer((_req, res) => { |