()
| 42 | })(); |
| 43 | |
| 44 | function getHosts() { |
| 45 | const result = ipManage.getAllSpeedTester(); |
| 46 | |
| 47 | const newHosts: HostData[] = []; |
| 48 | |
| 49 | result.forEach(item => { |
| 50 | newHosts.push({ |
| 51 | name: item.hostname, |
| 52 | ip: item.alive |
| 53 | }) |
| 54 | }); |
| 55 | |
| 56 | return buildHosts(newHosts); |
| 57 | } |
| 58 | |
| 59 | async function createServer({port}: { port: number }) { |
| 60 | const foundPort = await portfinder.getPortPromise({port}); |
no test coverage detected