Versions in this module Expand all Collapse all v1 v1.2.1 Mar 8, 2016 Changes in this version + func ConvertURLsToStrings(urls []*url.URL) []string + func IsHTTPURL(s string) bool + func LogAndReturnError(handler string, statusCode int, err error, w http.ResponseWriter) + func LogHandlerEntry(handler string, r *http.Request) + func LogHandlerExit(handler string, statusCode int, status string, w http.ResponseWriter) + func LogHandlerExitWithJSON(handler string, w http.ResponseWriter, v interface{}, statusCode int) + func LogHandlerExitWithText(handler string, w http.ResponseWriter, v string, statusCode int) + func LogHandlerExitWithYAML(handler string, w http.ResponseWriter, v interface{}, statusCode int) + func LogHandlerText(handler string, v string) + func MarshalAndWriteJSON(handler string, w http.ResponseWriter, v interface{}, statusCode int) []byte + func MarshalAndWriteYAML(handler string, w http.ResponseWriter, v interface{}, statusCode int) []byte + func NewTemplateFromArchive(name string, r io.Reader, importFileNames []string) (*common.Template, error) + func NewTemplateFromFileNames(templateFileName string, importFileNames []string) (*common.Template, error) + func NewTemplateFromReader(name string, r io.Reader, importFileNames []string) (*common.Template, error) + func NewTemplateFromRootTemplate(templateFileName string) (*common.Template, error) + func NewTemplateFromType(name, typeName string, properties map[string]interface{}) (*common.Template, error) + func ParseKubernetesObject(object []byte) (*common.Resource, error) + func TestHandlerWithURL(handler http.Handler, method, urlString string) (*httptest.ResponseRecorder, error) + func ToJSONOrError(v interface{}) string + func ToYAMLOrError(v interface{}) string + func TrimURLScheme(URL string) string + func WriteJSON(handler string, w http.ResponseWriter, j []byte, status int) + func WriteResponse(handler string, w http.ResponseWriter, v []byte, ct string, status int) + func WriteYAML(handler string, w http.ResponseWriter, y []byte, status int) + type HTTPClient interface + Get func(url string) (body string, code int, err error) + func DefaultHTTPClient() HTTPClient + func NewHTTPClient(retries uint, c HTTPDoer, s Sleeper) HTTPClient + type HTTPDoer interface + Do func(req *http.Request) (resp *http.Response, err error) + type HandlerTester func(method, path, ctype string, reader io.Reader) (*httptest.ResponseRecorder, error) + func NewHandlerTester(handler http.Handler) HandlerTester + func (h HandlerTester) TestWithURL(method, urlString string) (*httptest.ResponseRecorder, error) + type Kubernetes interface + Create func(resource string) (string, error) + Delete func(resource string) (string, error) + Get func(name string, resourceType string) (string, error) + Replace func(resource string) (string, error) + func NewKubernetesKubectl(config *KubernetesConfig) Kubernetes + type KubernetesConfig struct + KubeCertAuth string + KubeClientCert string + KubeClientKey string + KubeConfig string + KubeInsecure bool + KubePassword string + KubePath string + KubeServer string + KubeService string + KubeToken string + KubeUsername string + type KubernetesKubectl struct + Arguments []string + KubePath string + func (k *KubernetesKubectl) Create(resource string) (string, error) + func (k *KubernetesKubectl) Delete(resource string) (string, error) + func (k *KubernetesKubectl) Get(name string, resourceType string) (string, error) + func (k *KubernetesKubectl) Replace(resource string) (string, error) + type ServerTester func(method, path, ctype string, reader io.Reader) (*http.Response, error) + func NewServerTester(handler http.Handler) ServerTester + type Sleeper interface + Sleep func(d time.Duration) + func NewSleeper() Sleeper