Documentation ¶
Overview ¶
Package test implements utility routes to test the functionality provided by the injector package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Compare ¶
func Compare(functionName, actualFilename, expectedFilename, actualYAML, expectedYAML string)
Compare is a wrapper around gomega.Expect().To(Equal()) and compares actualYAML and expectedYAML; It also provides a verbose message when things don't match with a tip on how to fix things.
func LoadExpectedEnvoyYAML ¶
LoadExpectedEnvoyYAML loads the expectation for a given test from the file system. This must run within ginkgo.It()
func MarshalAndSaveToFile ¶
MarshalAndSaveToFile converts a generic Go struct into YAML and saves it to a file. This must run within ginkgo.It()
func ThisFunction ¶
func ThisFunction(functionName string, fn func() interface{})
ThisFunction runs the given function in a ginkgo.Context(), marshals the output and compares to an expectation loaded from file.
Types ¶
This section is empty.