1 import express from 'express'
2 import { Server } from 'http'
3 import { getPort, randomListen, terminateServer } from './shared'
5 export class MockHTTP {
11 app.get('/*', (req: express.Request, res: express.Response, next: express.NextFunction) => {
12 return res.sendStatus(200)
15 this.server = await randomListen(app)
17 return getPort(this.server)
21 return terminateServer(this.server)