@eggjs/supertest
Version:
SuperAgent driven library for testing HTTP servers
14 lines (13 loc) • 553 B
TypeScript
import { RequestListener } from "node:http";
import { Http2ServerRequest, Http2ServerResponse } from "node:http2";
import { AgentOptions } from "superagent";
import { Server } from "node:net";
//#region src/types.d.ts
type H2RequestListener = (request: Http2ServerRequest, response: Http2ServerResponse) => void;
type H1RequestListener = RequestListener;
type App = Server | H1RequestListener | H2RequestListener | string;
interface AgentOptions$1 extends AgentOptions {
http2?: boolean;
}
//#endregion
export { AgentOptions$1 as AgentOptions, App };