View definition

(*DockerServer).CustomHandler

Defined in github.com/fsouza/go-dockerclient/testing/server.go

Description

CustomHandler registers a custom handler for a specific path.

For example:

server.CustomHandler("/containers/json", http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
    http.Error(w, "Something wrong is not right", http.StatusInternalServerError)
}))