Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Dispatcher ¶
type Dispatcher struct { IP string Port int PortTLS int ConfigTLS string Resolver RequestResolver Translator mock.MessageTranslator Evaluator vars.Evaluator Scenario match.ScenearioStorer Spier match.TransactionSpier Mlog chan match.Transaction }
Dispatcher is the mock http server
func (*Dispatcher) ServeHTTP ¶
func (di *Dispatcher) ServeHTTP(w http.ResponseWriter, req *http.Request)
ServerHTTP is the mock http server request handler. It uses the router to decide the matching mock and translator as adapter between the HTTP impelementation and the mock mock.
type RequestResolver ¶
RequestResolver contains the functions to check the http request and return the matching mock.
Click to show internal directories.
Click to hide internal directories.