Documentation ¶
Overview ¶
Package test implements utilities for testing
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type HandlerSet ¶
type HandlerSet struct {
// contains filtered or unexported fields
}
HandlerSet is a struct with a mutex that allows us to swap handlers while a test server is running
func (*HandlerSet) ServeHTTP ¶
func (hs *HandlerSet) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP serves HTTP using the handler
func (*HandlerSet) SetHandler ¶
func (hs *HandlerSet) SetHandler(handler http.Handler)
SetHandler sets the handler to `handler`
Click to show internal directories.
Click to hide internal directories.