UNPKG

tools-mock

Version:

A node.js mock tool to quickly start the server via http

17 lines (16 loc) 607 B
/// <reference types="node" /> import * as http from 'http'; import CMockConfig from './CMockConfig'; import CMockRouter from './CMockRouter'; import CMockWSRouter from './CMockWSRouter'; import * as WebSocket from 'ws'; export default class CMockSer { server: http.Server<typeof http.IncomingMessage, typeof http.ServerResponse>; wsserver: WebSocket.Server<typeof import("ws"), typeof http.IncomingMessage>; CMockConfig: CMockConfig; CMockRouter: CMockRouter; CMockWSRouter: CMockWSRouter; constructor(CMockConfig: CMockConfig); run: () => Promise<any>; stop: () => void; }